- Issue created by @jeffreysmattson
- 🇮🇳India dineshkumarbollu
Hi jeffreysmattson
Created patch for this please review.Thanks - @jeffreysmattson opened merge request.
- 🇺🇸United States caspervoogt
I tried this patch on D10 and got:
PHP Fatal error: Could not check compatibility between Drupal\rest_absolute_urls\Normalizer\StringDataNormalizer::normalize($object, $format = null, array $context = []): Drupal\rest_absolute_urls\Normalizer\ArrayObject|array|string|int|float|bool|null and Drupal\serialization\Normalizer\PrimitiveDataNormalizer::normalize($object, $format = null, array $context = []): ArrayObject|array|string|int|float|bool|null, because class Drupal\rest_absolute_urls\Normalizer\ArrayObject is not available in /web/modules/contrib/rest_absolute_urls/src/Normalizer/StringDataNormalizer.php on line 40
Not sure it matters that I'm on D10
- 🇺🇸United States caspervoogt
So here's a patch which did work for me. Again, I'm on D10 so YMMV.
- 🇫🇷France xadag
Be carreful, on the patch number 5 you rename $object to $entity, to the instruction
$value = parent::normalize($object, $format, $context);
Don't know the variable $object
- 🇺🇸United States caspervoogt
thanks @fermicode and @cadag, my mistake moving fast and breaking things! I had to get my site updated to D10 quickly and obviously flubbed something on my patch.
-
fermicoder →
authored 0328e8ef on 8.x-1.x
Issue #3398715 by fermicoder: Fatal Error String Data Normalizer
-
fermicoder →
authored 0328e8ef on 8.x-1.x
- Status changed to Fixed
10 months ago 9:07am 23 February 2024 - Issue was unassigned.
Automatically closed - issue fixed for 2 weeks with no activity.