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

Make Unit type less ambiguous #221

carte7000 opened this issue Jan 7, 2020 · 1 comment

Make Unit type less ambiguous #221

carte7000 opened this issue Jan 7, 2020 · 1 comment


Copy link

@carte7000 carte7000 commented Jan 7, 2020

Given a contract with Unit as storage

Currently originating such a contract with null (or any truthy value) in the storage property work, but undefined don't
Also decoding the storage of such a contract always return null

See this commit for a summary of an example of the current behavior

Using null to represent the Unit value is ambiguous as it can have different meaning.

One solution would be to use a global constant ex: Taquito.Unit which would be required while encoding and returned while decoding storage which contains Unit type.

Copy link

@jevonearth jevonearth commented Feb 5, 2020


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

No branches or pull requests

2 participants