src/Execution/LighthouseRequest.php
public function variables(): array
    {
        $variables = $this->fieldValue('variables');

        // In case we are resolving a GET request, variables
        // are sent as a JSON encoded string
        if (is_string($variables)) {
            return json_decode($variables, true) ?? [];
        }

        // If this is a POST request, Laravel already decoded the input for us
        return $variables ?? [];
    }
public function variables(): array
    {
        $variables = $this->fieldValue('variables');

        // In case we are resolving a GET request, variables
        // are sent as a JSON encoded string
        if (is_string($variables)) {
            return json_decode($variables, true) ?? [];
        }

        // If this is a POST request, Laravel already decoded the input for us
        return $variables ?? [];
    }
public function variables ( ) : array { $ variables = $ this -> fieldValue ( 'variables' ) ; // In case we are resolving a GET request, variables // are sent as a JSON encoded string if ( is_string ( $ variables ) ) { return json_decode ( $ variables , true ) ?? [ ] ; } // If this is a POST request, Laravel already decoded the input for us return $ variables ?? [ ] ; }
Get the given variables for the query.

@return mixed[]
Get the given variables for the query .