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

lang: Number in method name causes incorrect serialization #736

Closed
armaniferrante opened this issue Sep 14, 2021 · 3 comments
Closed

lang: Number in method name causes incorrect serialization #736

armaniferrante opened this issue Sep 14, 2021 · 3 comments

Comments

@armaniferrante
Copy link
Member

my_method_2 doesn't serialize properly when testing with javascript. This is likely because the IDL's conversion to camelCase makes it ambiguous as to whether the name is my_method2 vs my_method_2. Fix should be to use snake_case in the IDL.

@paul-schaaf
Copy link
Contributor

paul-schaaf commented Nov 17, 2021

@armaniferrante just to make sure I understand correctly, are you saying that the IDL and therefore the clients should just use snake_case and we remove the conversion to camelCase? So the js function will look exactly like the anchor rust function?

@armaniferrante
Copy link
Member Author

This is addressed by #912.

@acheroncrypto
Copy link
Collaborator

Fixed in #2824.

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

No branches or pull requests

3 participants