|
@@ 277-279 (lines=3) @@
|
| 274 |
|
{ |
| 275 |
|
$variable = $variableReference->getVariable(); |
| 276 |
|
if ($argumentType->getKind() == TypeMap::KIND_LIST) { |
| 277 |
|
if ($variable->getTypeName() != $argumentType->getNamedType()->getName()) { |
| 278 |
|
throw new ResolveException(sprintf('Invalid variable "%s" type, allowed type is "%s"', $variable->getName(), $argumentType->getName())); |
| 279 |
|
} |
| 280 |
|
} else { |
| 281 |
|
if ($variable->getTypeName() != $argumentType->getName()) { |
| 282 |
|
throw new ResolveException(sprintf('Invalid variable "%s" type, allowed type is "%s"', $variable->getName(), $argumentType->getName())); |
|
@@ 280-284 (lines=5) @@
|
| 277 |
|
if ($variable->getTypeName() != $argumentType->getNamedType()->getName()) { |
| 278 |
|
throw new ResolveException(sprintf('Invalid variable "%s" type, allowed type is "%s"', $variable->getName(), $argumentType->getName())); |
| 279 |
|
} |
| 280 |
|
} else { |
| 281 |
|
if ($variable->getTypeName() != $argumentType->getName()) { |
| 282 |
|
throw new ResolveException(sprintf('Invalid variable "%s" type, allowed type is "%s"', $variable->getName(), $argumentType->getName())); |
| 283 |
|
} |
| 284 |
|
} |
| 285 |
|
|
| 286 |
|
$requestValue = $request->getVariable($variable->getName()); |
| 287 |
|
if (!$request->hasVariable($variable->getName()) || (null === $requestValue && $variable->isNullable())) { |