Skip to content
Snippets Groups Projects
Commit 6aa318a0 authored by Noe Nieto's avatar Noe Nieto :speech_balloon:
Browse files

Hook the sanitize_username to the plugin boilerplate

parent 43330991
No related branches found
No related tags found
No related merge requests found
......@@ -10,9 +10,11 @@ Version: 0.1
Author URI: http://www.puri.sm/
*/
include 'sanitize.php';
function purism_pre_user_login_filter($sanitized_user_login){
// do your sanitization with $sanitized_user_login
return $sanitized_user_login;
return sanitize_username($sanitized_user_login);
}
add_filter('pre_user_login', 'purism_pre_user_login_filter', 10, 3);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment