File tree Expand file tree Collapse file tree 2 files changed +26
-1
lines changed
src/Packages/Passport/Runtime/Scripts/Private/Model/Response Expand file tree Collapse file tree 2 files changed +26
-1
lines changed Original file line number Diff line number Diff line change @@ -413,7 +413,21 @@ public async void GetZkTransactionReceiptStatus()
413413 ShowOutput ( $ "Getting zkEVM transaction receipt status...") ;
414414
415415 TransactionReceiptResponse response = await passport . ZkEvmGetTransactionReceipt ( ZkGetTransactionReceiptHash . text ) ;
416+ string status = "Transaction receipt status: " ;
416417 ShowOutput ( $ "Transaction receipt status: { ( response . status == "0x1" ? "Success" : "Failed" ) } ") ;
418+ switch ( response . status )
419+ {
420+ case "0x1" :
421+ status += "Success" ;
422+ break ;
423+ case "0x0" :
424+ status += "Failed" ;
425+ break ;
426+ case null :
427+ status += "Still processing" ;
428+ break ;
429+ }
430+ ShowOutput ( status ) ;
417431 }
418432 catch ( Exception ex )
419433 {
Original file line number Diff line number Diff line change @@ -21,7 +21,18 @@ public class TransactionReceiptResponse
2121 public string logsBloom ;
2222
2323 /// <summary>
24- /// Either 1 (success) or 0 (failure) encoded as a hexadecimal.
24+ /// Possible reponses:
25+ /// <list type="bullet">
26+ /// <item>
27+ /// <description>Success: 0x0</description>
28+ /// </item>
29+ /// <item>
30+ /// <description>Failure: 0x0</description>
31+ /// </item>
32+ /// <item>
33+ /// <description>Null: Transaction is still processing</description>
34+ /// </item>
35+ /// </list>
2536 /// </summary>
2637 public string status ;
2738
You can’t perform that action at this time.
0 commit comments