Exiting the program in case the functional options have been defined in the wrong order is a bit extrem imo
I would prefer one of the following:
WithPdkdf2Password also takes a salt and the user must not also call WithSalt
WalletKey has a verify method that is called after applying all functional options that verifies a correct state and returns an error if something is missing (e.g. no salt provided)
I would prefer one of the following:
WithPdkdf2Password
also takes asalt
and the user must not also callWithSalt
WalletKey
has averify
method that is called after applying all functional options that verifies a correct state and returns an error if something is missing (e.g. no salt provided)_Originally posted by @fasmat in https://github.com/spacemeshos/smcli/pull/20#discussion_r1153727168_