If a function has multi events , the first successed but second faile. Can I get all of them in block?

solidity code like this

emit event1
emit event2


throw rolls back the whole transaction, so it not only prevents event2 from being emitted, but also rolls back emission of event1. The final effect will be as if no events were logged at all, so you will see neither event1 nor event2 in transaction.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.