breacharbiter: check ErrDoubleSpend from PublishTransaction

This commit is contained in:
Johan T. Halseth committed 2018-02-14 12:34:42 +01:00
1 parent 2ae1b7dbbe
commit cabc07ea7d
1 file changed
+1 -2
+1 -2
View File
@@ -5,7 +5,6 @@ import (
"encoding/binary" "encoding/binary"
"errors" "errors"
"io" "io"
"strings"
"sync" "sync"
"sync/atomic" "sync/atomic"
@@ -580,7 +579,7 @@ secondLevelCheck:
if err != nil { if err != nil {
brarLog.Errorf("unable to broadcast "+ brarLog.Errorf("unable to broadcast "+
"justice tx: %v", err) "justice tx: %v", err)
if strings.Contains(err.Error(), "already been spent") { if err == lnwallet.ErrDoubleSpend {
brarLog.Infof("Attempting to transfer HTLC revocations " + brarLog.Infof("Attempting to transfer HTLC revocations " +
"to the second level") "to the second level")
finalTx = nil finalTx = nil