Skip to content

Instantly share code, notes, and snippets.

@heiglandreas
Last active September 17, 2015 12:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save heiglandreas/96ea229eb37b474d1e42 to your computer and use it in GitHub Desktop.
Save heiglandreas/96ea229eb37b474d1e42 to your computer and use it in GitHub Desktop.
<?php
add_filter('authenticate', function($user, $username, $password){
$userId = $user;
if ($user instanceof WP_User) {
$userId = $user->ID;
}
ataccama_permissions_setUserPermissions($userId);
return $user;
}, 20,1);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment