--- a/pallets/nft/src/lib.rs +++ b/pallets/nft/src/lib.rs @@ -1799,9 +1799,6 @@ } }; - // call event - Self::deposit_event(RawEvent::ItemCreated(collection_id, ::get(collection_id), owner)); - Ok(()) } @@ -1825,6 +1822,7 @@ .ok_or(Error::::NumOverflow)?; >::insert(collection_id, (*owner).clone(), new_balance); + Self::deposit_event(RawEvent::ItemCreated(collection_id, 0, owner.clone())); Ok(()) } @@ -1848,6 +1846,7 @@ .ok_or(Error::::NumOverflow)?; >::insert(collection_id, owner.clone(), new_balance); + Self::deposit_event(RawEvent::ItemCreated(collection_id, current_index, owner)); Ok(()) } @@ -1868,6 +1867,7 @@ .ok_or(Error::::NumOverflow)?; >::insert(collection_id, item_owner.clone(), new_balance); + Self::deposit_event(RawEvent::ItemCreated(collection_id, current_index, item_owner)); Ok(()) }