File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change 1515
1616namespace FastyBird \JsonApi \Hydrators \Fields ;
1717
18+ use BackedEnum ;
1819use IPub \JsonAPIDocument ;
1920use function call_user_func ;
2021use function is_callable ;
@@ -45,7 +46,7 @@ public function __construct(
4546 /**
4647 * @param JsonAPIDocument\Objects\IStandardObject<string, mixed> $attributes
4748 */
48- public function getValue (JsonAPIDocument \Objects \IStandardObject $ attributes ): \ BackedEnum |null
49+ public function getValue (JsonAPIDocument \Objects \IStandardObject $ attributes ): BackedEnum |null
4950 {
5051 $ value = $ attributes ->get ($ this ->getMappedName ());
5152
@@ -54,7 +55,7 @@ public function getValue(JsonAPIDocument\Objects\IStandardObject $attributes): \
5455 if (is_callable ($ callable )) {
5556 $ result = $ value !== null ? call_user_func ($ callable , $ value ) : null ;
5657
57- return $ result instanceof \ BackedEnum ? $ result : null ;
58+ return $ result instanceof BackedEnum ? $ result : null ;
5859 }
5960
6061 return null ;
Original file line number Diff line number Diff line change 1616namespace FastyBird \JsonApi \Hydrators ;
1717
1818use ArrayAccess ;
19+ use BackedEnum ;
1920use DateTimeInterface ;
2021use Doctrine \Common ;
2122use Doctrine \ORM ;
@@ -539,7 +540,7 @@ protected function mapEntity(string $entityClassName): array
539540 $ isWritable ,
540541 );
541542
542- } elseif ($ typeRc ->isSubclassOf (\ BackedEnum::class)) {
543+ } elseif ($ typeRc ->isSubclassOf (BackedEnum::class)) {
543544 $ fields [] = new Hydrators \Fields \BackedEnumField (
544545 $ className ,
545546 $ isNullable ,
You can’t perform that action at this time.
0 commit comments