public function shouldMutate(array $attributes)
    {
        $grammar = $this->getQuery()->getGrammar();
        $attributes = array_map([$grammar, 'cropLabelIdentifier'], array_keys($attributes));
        $mutations = array_keys($this->mutations);

        $intersect = array_intersect($attributes, $mutations);

        return ! empty($intersect);
    }
public function shouldMutate(array $attributes)
    {
        $grammar = $this->getQuery()->getGrammar();
        $attributes = array_map([$grammar, 'cropLabelIdentifier'], array_keys($attributes));
        $mutations = array_keys($this->mutations);

        $intersect = array_intersect($attributes, $mutations);

        return ! empty($intersect);
    }
public function shouldMutate ( array $ attributes ) { $ grammar = $ this -> getQuery ( ) -> getGrammar ( ) ; $ attributes = array_map ( [ $ grammar , 'cropLabelIdentifier' ] , array_keys ( $ attributes ) ) ; $ mutations = array_keys ( $ this -> mutations ) ; $ intersect = array_intersect ( $ attributes , $ mutations ) ; return ! empty ( $ intersect ) ; }
Determine whether attributes are mutations
and should be transformed back. It is considered
a mutation only when the attributes' keys
and mutations keys match.

@param  array  $attributes
@return boolean
Determine whether attributes are mutations and should be transformed back . It is considered a mutation only when the attributes keys and mutations keys match .