mirror of
https://github.com/aljazceru/breez-lnd.git
synced 2026-02-22 06:54:20 +01:00
tlv: display the unknown primitive type in MakePrimitiveRecord error message
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package tlv
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"io"
|
||||
|
||||
"github.com/btcsuite/btcd/btcec"
|
||||
@@ -126,7 +127,7 @@ func MakePrimitiveRecord(typ Type, val interface{}) Record {
|
||||
decoder = DVarBytes
|
||||
|
||||
default:
|
||||
panic("unknown primitive type")
|
||||
panic(fmt.Sprintf("unknown primitive type: %T", val))
|
||||
}
|
||||
|
||||
return Record{
|
||||
|
||||
Reference in New Issue
Block a user