Skip to content

Commit 5b5c08c

Browse files
Seongjae ChoiSeongjae Choi
authored andcommitted
Handle sequence number bigger than byte range
1 parent f852f19 commit 5b5c08c

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

core/transaction/mintAsset.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ func (t *MintAsset) Sign(secret primitives.H256, seq uint, fee primitives.U64) c
134134
}
135135

136136
func (t MintAsset) ToEncodeObject() []interface{} {
137-
return []interface{}{byte(t.Seq()), t.Fee().ToEncodeObject(), t.NetworkID(), append(t.ActionToEncodeObject(), t.Approvals)}
137+
return []interface{}{t.Seq(), t.Fee().ToEncodeObject(), t.NetworkID(), append(t.ActionToEncodeObject(), t.Approvals)}
138138
}
139139

140140
func (t MintAsset) UnsignedHash() primitives.H256 {

core/transaction/pay.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ func (p Pay) ActionToEncodeObject() []interface{} {
3535
}
3636

3737
func (p Pay) ToEncodeObject() []interface{} {
38-
return []interface{}{byte(p.Seq()), p.Fee().ToEncodeObject(), p.NetworkID(), p.ActionToEncodeObject()}
38+
return []interface{}{p.Seq(), p.Fee().ToEncodeObject(), p.NetworkID(), p.ActionToEncodeObject()}
3939
}
4040

4141
func (p Pay) ActionToJSON() interface{} {

0 commit comments

Comments
 (0)