Commit b0495043 authored by Viral Solani's avatar Viral Solani

resolve user permissions error

parent c10511e3
......@@ -352,8 +352,8 @@ class UserRepository extends BaseRepository
*/
protected function flushPermissions($permissions, $user)
{
//Flush roles out, then add array of new ones
$user->detachPermissions($user->roles);
//Flush permission out, then add array of new ones
$user->detachPermissions($user->permissions);
$user->attachPermissions($permissions);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment