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
wallet: accept language option for mnemonic when creating new wallet #588
Conversation
Pull Request Test Coverage Report for Build 1163870793
💛 - Coveralls |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this only applies when you want wallet to generate mnemonic. (w/o passing phrase)
Otherwise if mnemonic has the phrase it will be used to detect language.
Check is becomes kinda weird: if mnemonic is null becomes the only case when language
will be applied, so if (!(mnemonic instanceof Mnemonic))
will only happen when mnemonic is null/undefined
?
In that case it can be rewritten as if (!mnemonic)
..
Unless manually called with string
type as in test should create wallet with spanish mnemonic
in wallet-test
.
Rebased on master and also added an explicit error if an unknown language is requested: (still requires handshake-org/hs-client#39 to test)
|
Closes #587
Once handshake-org/hs-client#39 is merged together: