mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-09-27 20:57:19 +02:00
htlcswitch: add ForwardingError constructor
Add a constructor for the creation of forwarding errors. A special constructor is added for the case where we have an unknown wire failure, and must set a nil failure message.
This commit is contained in:
@@ -400,10 +400,7 @@ func (o *mockDeobfuscator) DecryptError(reason lnwire.OpaqueReason) (*Forwarding
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return &ForwardingError{
|
||||
FailureSourceIdx: 1,
|
||||
FailureMessage: failure,
|
||||
}, nil
|
||||
return NewForwardingError(failure, 1, ""), nil
|
||||
}
|
||||
|
||||
var _ ErrorDecrypter = (*mockDeobfuscator)(nil)
|
||||
|
Reference in New Issue
Block a user