/** * Get applied restrictions matching a given restriction name * * Returns a list of applied restrictions, empty if no user is * authenticated * * @param string $restriction Restriction name * @return array */ public function getRestrictions($restriction) { if (!$this->isAuthenticated()) { return array(); } return $this->user->getRestrictions($restriction); }