public function exceedsLimit($user_id, $store_id)
    {
        if ($this->user->isSuperadmin($user_id)) {
            return false; // No limits for superadmin
        }

        $limit = $this->getLimit($user_id);

        if (empty($limit)) {
            return false;
        }

        $conditions = array(
            'user_id' => $user_id,
            'store_id' => $store_id
        );

        $existing = $this->getList($conditions);
        return count($existing) > $limit;
    }
public function exceedsLimit($user_id, $store_id)
    {
        if ($this->user->isSuperadmin($user_id)) {
            return false; // No limits for superadmin
        }

        $limit = $this->getLimit($user_id);

        if (empty($limit)) {
            return false;
        }

        $conditions = array(
            'user_id' => $user_id,
            'store_id' => $store_id
        );

        $existing = $this->getList($conditions);
        return count($existing) > $limit;
    }
public function exceedsLimit ( $ user_id , $ store_id ) { if ( $ this -> user -> isSuperadmin ( $ user_id ) ) { return false ; // No limits for superadmin } $ limit = $ this -> getLimit ( $ user_id ) ; if ( empty ( $ limit ) ) { return false ; } $ conditions = array ( 'user_id' => $ user_id , 'store_id' => $ store_id ) ; $ existing = $ this -> getList ( $ conditions ) ; return count ( $ existing ) > $ limit ; }
Whether the user exceeds the max allowed number of products in the wishlist
@param integer|string $user_id
@param integer $store_id
@return boolean
Whether the user exceeds the max allowed number of products in the wishlist