You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@frodeborli thanks for putting together this serializer! While giving it a shot, I'm running into an issue with uninitialized properties. Here is a stacktrace, when processing the Webonyx GraphQL schema:
I took a quick look into this. However, I'm not sure how the $frozen array is going to hold uninitialized properties. I guess there will need to be a special value assigned to it that can be translated during the unserialization. I didn't get a chance to look into the unserialize in detail to see how that might be done. I suspect it might be tricky to dynamically create uninitialized properties on an object at runtime.
The text was updated successfully, but these errors were encountered:
Thanks! I made a simple test case and fixed the issue. If the value is uninitialized it won't be added to the Stasis::$p array, and then it won't be set on the new instance - leaving it uninitialized. Let me know if there are other problems and perhaps I can fix them too.
@frodeborli thanks for putting together this serializer! While giving it a shot, I'm running into an issue with uninitialized properties. Here is a stacktrace, when processing the Webonyx GraphQL schema:
I tried setting some default values on some properties in various classes, but it looks like it's going to be a lot of them. PHP's
ReflectionProperty
has theisInitialized
method (https://www.php.net/manual/en/reflectionproperty.isinitialized.php).I took a quick look into this. However, I'm not sure how the
$frozen
array is going to hold uninitialized properties. I guess there will need to be a special value assigned to it that can be translated during the unserialization. I didn't get a chance to look into theunserialize
in detail to see how that might be done. I suspect it might be tricky to dynamically create uninitialized properties on an object at runtime.The text was updated successfully, but these errors were encountered: