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
@kirillshevch I'm using version 1.0.5, and there seems to be an issue with serializing related entities - here's a quick and dirty example with the Stripe API:
module StripeApi
module Entities
class Person < ApiStruct::Entity
client_service StripeApi::Clients::Persons
attr_entity :id,
:first_name,
:last_name
has_entity :verification, as: StripeApi::Entities::Verification
end
end
end
module StripeApi
module Entities
class Verification < ApiStruct::Entity
client_service StripeApi::Clients::Persons
attr_entity :status,
:details,
:details_code
end
end
end
With those two serializers in place, when I call StripeApi::Entities::Person.show <params>, here's what I get:
Essentially the verification field on the Person entity gets deserialized as if it was a attr_entity :verification - the Verification entity fails to exclude all params except status, details and details_code. What do you think?
Activity