src/Serializer/ModelSerializer.php
private function isExpandable(Model $model, $k, $value)
    {
        // if the value is falsey then do not expand it
        // could be null, excluded, or not included
        if (!$value) {
            return false;
        }

        // if not a property or no relationship model specified
        // then do not expand
        $property = $model::getProperty($k);
        if (!$property || !isset($property['relation'])) {
            return false;
        }

        return true;
    }
private function isExpandable(Model $model, $k, $value)
    {
        // if the value is falsey then do not expand it
        // could be null, excluded, or not included
        if (!$value) {
            return false;
        }

        // if not a property or no relationship model specified
        // then do not expand
        $property = $model::getProperty($k);
        if (!$property || !isset($property['relation'])) {
            return false;
        }

        return true;
    }
private function isExpandable ( Model $ model , $ k , $ value ) { // if the value is falsey then do not expand it // could be null, excluded, or not included if ( ! $ value ) { return false ; } // if not a property or no relationship model specified // then do not expand $ property = $ model :: getProperty ( $ k ) ; if ( ! $ property || ! isset ( $ property [ 'relation' ] ) ) { return false ; } return true ; }
Expands a model.

@param Model  $model
@param string $k
@param mixed  $value

@return bool
Expands a model .