You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is super useful to prevent accidental mistakes, but occasionally people will accidentally use the payToAddressWithData method instead, which bypasses this check.
If we made this method private, and added payToNativeScriptWithData and payToWalletAddressWithData that, respectively, required you to pass the native address and required you to pass a non-script address, this could solve some accidental use of the library.
The text was updated successfully, but these errors were encountered:
Makes sense but generally we're keeping the lucid apis for compatibility, with intent to move away entirely at some point. Later variations can have such considerations.
Given recent issues, I'd like to propose updating the surface API of translucent to prevent accidental mistakes.
Currently, payToContract prevents sending to a smart contract if no datum is attached.
This is super useful to prevent accidental mistakes, but occasionally people will accidentally use the payToAddressWithData method instead, which bypasses this check.
If we made this method private, and added
payToNativeScriptWithData
andpayToWalletAddressWithData
that, respectively, required you to pass the native address and required you to pass a non-script address, this could solve some accidental use of the library.The text was updated successfully, but these errors were encountered: