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

proper contract error on cw721 instantiation #47

Open
taitruong opened this issue Feb 17, 2023 · 0 comments
Open

proper contract error on cw721 instantiation #47

taitruong opened this issue Feb 17, 2023 · 0 comments

Comments

@taitruong
Copy link
Collaborator

Currently only success case is handled: https://github.com/public-awesome/ics721/blob/main/contracts/cw-ics721-bridge/src/contract.rs#L266

In case ics721 contract is instantiated with wrong CW721_CODE_ID, during transfer this ack fail is returned:

{"error":"codespace: wasm, code: 4"}

SDK error with code 4 means unauthorized.

In additional pls also have a look here: https://github.com/public-awesome/ics721/blob/main/contracts/cw-ics721-bridge/src/contract.rs#L39

    let proxy_instantiate = msg
        .proxy
        .map(|m| m.into_wasm_msg(env.contract.address))
        .map(|wasm| SubMsg::reply_on_success(wasm, INSTANTIATE_PROXY_REPLY_ID))
        .map_or(vec![], |s| vec![s]);
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

No branches or pull requests

1 participant