-
Notifications
You must be signed in to change notification settings - Fork 215
Sync Role Permissions
Kodeine edited this page Feb 23, 2015
·
1 revision
You can pass an array of role objects,ids or slugs to sync them to a user.
$roleAdmin->syncPermissions([1,2,3]);
$roleAdmin->syncPermissions('user, post');
$roleAdmin->syncPermissions((array($permUser, $permPost));
Note: The system will throw an exception if role does not exists.