Skip to content
This repository was archived by the owner on Mar 28, 2023. It is now read-only.

Commit 9573645

Browse files
committed
Do not process FIL txs with no order id
1 parent 5a7c3f6 commit 9573645

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

wallet/listeners/transaction_listener.go

+6
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ package bitcoin
22

33
import (
44
"math/big"
5+
"strings"
56
"sync"
67
"time"
78

@@ -92,6 +93,11 @@ func (l *TransactionListener) cleanupOrderState(isSale bool, contract *pb.Ricard
9293
func (l *TransactionListener) OnTransactionReceived(cb wallet.TransactionCallback) {
9394
l.Lock()
9495
defer l.Unlock()
96+
97+
if strings.HasPrefix(cb.Txid, "bafy") && cb.Outputs[0].OrderID == "" {
98+
return
99+
}
100+
95101
for _, output := range cb.Outputs {
96102
if output.Address == nil {
97103
continue

0 commit comments

Comments
 (0)