mirror of
https://github.com/retailcrm/graphql-php.git
synced 2024-11-25 06:16:05 +03:00
Add one more breaking change in 0.12
(cherry picked from commit 300b580
)
This commit is contained in:
parent
57c77623ee
commit
91daa23c5f
17
UPGRADE.md
17
UPGRADE.md
@ -10,6 +10,23 @@ Exception inside `parseLiteral()`, `parseValue()` and `serialize()`.
|
|||||||
|
|
||||||
Returning null from any of these methods will now be treated as valid result.
|
Returning null from any of these methods will now be treated as valid result.
|
||||||
|
|
||||||
|
### Breaking: Custom scalar types parseLiteral() declaration changed
|
||||||
|
A new parameter was added to `parseLiteral()`, which also needs to be added to any custom scalar type extending from `ScalarType`
|
||||||
|
|
||||||
|
Before:
|
||||||
|
```php
|
||||||
|
public function parseLiteral($valueNode) {
|
||||||
|
//custom implementation
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
After:
|
||||||
|
```php
|
||||||
|
public function parseLiteral($valueNode, array $variables = null) {
|
||||||
|
//custom implementation
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
### Breaking: Descriptions in comments are not used as descriptions by default anymore
|
### Breaking: Descriptions in comments are not used as descriptions by default anymore
|
||||||
Descriptions now need to be inside Strings or BlockStrings in order to be picked up as
|
Descriptions now need to be inside Strings or BlockStrings in order to be picked up as
|
||||||
description. If you want to keep the old behaviour you can supply the option `commentDescriptions`
|
description. If you want to keep the old behaviour you can supply the option `commentDescriptions`
|
||||||
|
Loading…
Reference in New Issue
Block a user