Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Encryption of boolean false values returns nil #754

Closed
casiodk opened this issue Aug 18, 2020 · 3 comments
Closed

Encryption of boolean false values returns nil #754

casiodk opened this issue Aug 18, 2020 · 3 comments

Comments

@casiodk
Copy link

casiodk commented Aug 18, 2020

Hi guys.

I am using the encryption mapper, and noticed that when encrypting boolean false values it returns nil when decrypting. Have you come across this issue before?

@mpraglowski
Copy link
Member

Nice find. I've prepared a failing test case for it and I could confirm the issue.

       Diff:

       @@ -1,5 +1,5 @@
       -#<RubyEventStore::Mappers::SomeEventWithPersonalInfo:0x00007f9e67156e88
       - @data={:personal_info=>false, :user_id=>123},
       +#<RubyEventStore::Mappers::SomeEventWithPersonalInfo:0x00007f9e578819e8
       + @data={:personal_info=>nil, :user_id=>123},

mpraglowski added a commit that referenced this issue Aug 19, 2020
mpraglowski added a commit that referenced this issue Aug 19, 2020
During encryption boolean values set to false have
been replaced by nils - that caused the value set to nil in decrypted
domain event.
@mpraglowski
Copy link
Member

Fixed and released in 1.1.1

@casiodk
Copy link
Author

casiodk commented Aug 20, 2020

Thanks for the quick fix 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants