Skip to content

Commit e384565

Browse files
authored
aider: don't try to decode signatures, they are already decoded (#1038)
Signed-off-by: Jakub Sztandera <[email protected]>
1 parent 8a3c0e6 commit e384565

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

observer/model.go

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
package observer
22

33
import (
4-
"encoding/base64"
54
"fmt"
65
"time"
76

@@ -249,17 +248,10 @@ func (j *Justification) ToGpbftJustification() (*gpbft.Justification, error) {
249248
return nil, fmt.Errorf("could not convert vote to gpbft payload: %w", err)
250249
}
251250

252-
// Embedded struct as json, hence the decode.
253-
s := string(j.Signature)
254-
decoded, err := base64.StdEncoding.DecodeString(s)
255-
if err != nil {
256-
return nil, fmt.Errorf("could not decode signature: %w", err)
257-
}
258-
259251
return &gpbft.Justification{
260252
Vote: payload,
261253
Signers: gsigners,
262-
Signature: decoded,
254+
Signature: j.Signature,
263255
}, nil
264256
}
265257

0 commit comments

Comments
 (0)