1- use std:: { default , fmt:: Display , time:: Duration } ;
1+ use std:: { fmt:: Display , time:: Duration } ;
22
33use cosmwasm_schema:: cw_serde;
44use cosmwasm_std:: {
55 Addr , BankMsg , Binary , Coin , CosmosMsg , CustomMsg , Deps , DepsMut , Empty , Env , MessageInfo ,
6- Response , StdResult , SubMsg , Timestamp , coin,
6+ Response , StdResult , SubMsg , coin,
77} ;
88use cw721:: {
99 Expiration ,
@@ -18,9 +18,8 @@ use cw721::{
1818use crate :: {
1919 error:: ContractError ,
2020 msg:: AssetExtensionExecuteMsg ,
21- plugin,
2221 state:: { AssetConfig , Reserve } ,
23- traits:: { AssetContract , DefaultAssetContract , SellableAsset } ,
22+ traits:: { DefaultAssetContract , SellableAsset } ,
2423} ;
2524
2625/// Shared context passed through the pipeline, mutated by plugins.
@@ -464,15 +463,21 @@ where
464463 plugin_ctx_deductions = plugin_ctx. deductions . clone ( ) ;
465464 } ;
466465 let mut response = match & msg {
467- Cw721ExecuteMsg :: UpdateExtension { msg : extension_msg } => {
468- match extension_msg {
469- AssetExtensionExecuteMsg :: Buy { token_id, recipient } => {
470- self . buy ( deps, env, info, ( * token_id) . clone ( ) , ( * recipient) . clone ( ) , plugin_ctx_deductions) ?
471- } ,
472- _ => self . execute ( deps, env, info, msg) ?,
473- }
466+ Cw721ExecuteMsg :: UpdateExtension { msg : extension_msg } => match extension_msg {
467+ AssetExtensionExecuteMsg :: Buy {
468+ token_id,
469+ recipient,
470+ } => self . buy (
471+ deps,
472+ env,
473+ info,
474+ ( * token_id) . clone ( ) ,
475+ ( * recipient) . clone ( ) ,
476+ plugin_ctx_deductions,
477+ ) ?,
478+ _ => self . execute ( deps, env, info, msg) ?,
474479 } ,
475- _ => self . execute ( deps, env, info, msg) ?,
480+ _ => self . execute ( deps, env, info, msg) ?,
476481 } ;
477482
478483 response. messages . extend ( plugin_response. messages ) ;
0 commit comments