hasPermission()
hasPermission(string $domain = null, integer $permmask = null) : boolean
Checks whether the current user has administrative permissions over the requested domain at the given permissions level.
Also checks to see if the user is a Vilma superadmin. If the user is a Horde admin they automatically have permission.
Parameters
string | $domain | Domain for which to check permissions. |
integer | $permmask | Permissions that must be set for the user. |
Returns
boolean —True if the user has the requested permission.