public function isUserSuperAdministrator($userId) {
        $result = DB::table('user_group')
            ->where('user_id', $userId)
            ->where('group_id', 3)
            ->first()
        ;

        if (!$result) {
            return false;
        }

        return true;
    }
public function isUserSuperAdministrator($userId) {
        $result = DB::table('user_group')
            ->where('user_id', $userId)
            ->where('group_id', 3)
            ->first()
        ;

        if (!$result) {
            return false;
        }

        return true;
    }
public function isUserSuperAdministrator ( $ userId ) { $ result = DB :: table ( 'user_group' ) -> where ( 'user_id' , $ userId ) -> where ( 'group_id' , 3 ) -> first ( ) ; if ( ! $ result ) { return false ; } return true ; }
Does the user belong to the Super Administrator user group?

It is assumed that Super Administrator is ID=3 in the groups database table.

@param  int $userId
@return bool
Does the user belong to the Super Administrator user group?