for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Drupal\graphql\GraphQL\Type;
use Youshido\GraphQL\Type\Scalar\AbstractScalarType;
class UndefinedType extends AbstractScalarType {
/**
* {@inheritdoc}
*/
public function getName() {
return 'Undefined';
}
public function serialize($value) {
if (is_scalar($value)) {
return (string) $value;
if (is_object($value) || is_array($value)) {
return json_encode($value);
return '';