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

refactor: rename Token and UserToken #1110

Merged
merged 2 commits into from
Apr 16, 2024

Conversation

peterpeterparker
Copy link
Member

Motivation

In PR #1100 we discussed the fact that using UserToken and CustomToken was confusing. This was the result of the fact that the original custom token for user for ERC20 which exists on mainnet are called Token and the related functions are called add_user_token.

To clean-up and make this more comprehensive, this PR rename the various structs.

  • Token -> UserToken (ERC20, already in prod and relates to add_user_token which won't change)
  • UserToken -> CustomToken (new custom token type we have recently added)
  • CustomToken -> Token (the token enum that contains either ICRC token or future other tokens)

Notes

After this PR, I'll provide a PR that renames the new functions that are not yet live on mainnet (set_user_custom_token -> set_custom_token).

This PR does not update the did file on purpose to narrow the number of changes in the PR. I'll provide a separate PR here as well for tracability reason.

@peterpeterparker peterpeterparker merged commit 701331e into main Apr 16, 2024
3 checks passed
@peterpeterparker peterpeterparker deleted the refactor/rename-user-custom-token-struct branch April 16, 2024 09:59
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

Successfully merging this pull request may close these issues.

1 participant