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

Fix incorrect field types in several request structs #108

Open
kevin-pease opened this issue Sep 12, 2024 · 0 comments · May be fixed by #109
Open

Fix incorrect field types in several request structs #108

kevin-pease opened this issue Sep 12, 2024 · 0 comments · May be fixed by #109
Labels
enhancement An enhancement of an existing feature invalid This doesn't seem right

Comments

@kevin-pease
Copy link
Contributor

kevin-pease commented Sep 12, 2024

There are 3 fields in 2 structs that are of the type Option<Asset<IssuedAsset>>, which is incorrect. It should be possible for them to contain a native asset as well. The affected structs:

  • all_claimable_balances_request: field asset;
  • all_offers_request: fields selling and buying.

The above asset type can be confusing, because we already have an AssetType in our request models. This type, however, can be of 3 types: native, alphanum4, and alphanum12. In some cases, an asset can be of 2 types: native and issued, which is the case for this issue.

We should introduce this new asset type in our request models. We should also check the rest of the codebase if the asset type with 2 options occurs in more request structs, and have them implement the new type.

@kevin-pease kevin-pease added invalid This doesn't seem right enhancement An enhancement of an existing feature labels Sep 12, 2024
@kevin-pease kevin-pease linked a pull request Sep 13, 2024 that will close this issue
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An enhancement of an existing feature invalid This doesn't seem right
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant