Skip to content

Commit

Permalink
Added a ueuser function for checking if a user has a specific role on…
Browse files Browse the repository at this point in the history
… a page
  • Loading branch information
ShawnClake committed Apr 15, 2017
1 parent 36518fe commit dbac98e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions components/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -414,4 +414,9 @@ public function profilePage($param = '')
$url .= '/' . $param;
return $url;
}

public function isInRole($roleCode)
{
return UserRoleManager::currentUser()->isInRole($roleCode);
}
}

0 comments on commit dbac98e

Please sign in to comment.