public function hasAccess($permissions)
    {
        if ($this->permissions->isEmpty())
        {
            $this->mergePermissions($this->userPermissions, $this->rolePermissions);
        }

        if (func_num_args() > 1)
        {
            $permissions = func_get_args();
        }

        foreach ((array) $permissions as $permissionName)
        {
            if (! $this->allows($permissionName))
            {
                return false;
            }
        }

        return true;
    }
public function hasAccess($permissions)
    {
        if ($this->permissions->isEmpty())
        {
            $this->mergePermissions($this->userPermissions, $this->rolePermissions);
        }

        if (func_num_args() > 1)
        {
            $permissions = func_get_args();
        }

        foreach ((array) $permissions as $permissionName)
        {
            if (! $this->allows($permissionName))
            {
                return false;
            }
        }

        return true;
    }
public function hasAccess ( $ permissions ) { if ( $ this -> permissions -> isEmpty ( ) ) { $ this -> mergePermissions ( $ this -> userPermissions , $ this -> rolePermissions ) ; } if ( func_num_args ( ) > 1 ) { $ permissions = func_get_args ( ) ; } foreach ( ( array ) $ permissions as $ permissionName ) { if ( ! $ this -> allows ( $ permissionName ) ) { return false ; } } return true ; }
Returns if access is available for all given permissions.

@param  array|string $permissions

@return bool
Returns if access is available for all given permissions .