Skip to content

Commit

Permalink
feat : update liblog to use SDKv0.50.0 (#1043)
Browse files Browse the repository at this point in the history
* liblog changes
  • Loading branch information
ruthishvitwit authored Nov 27, 2023
1 parent 403c80d commit 18a2d0e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
5 changes: 4 additions & 1 deletion util/liblog/liblog.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package liblog

import (
"github.com/cometbft/cometbft/libs/log"
"cosmossdk.io/log"
)

type Logr interface {
Expand All @@ -13,6 +13,9 @@ type Logr interface {
func FromSDKLogger(l log.Logger) Logr {
return &lgwr{l: l}
}
func (l *lgwr) Impl() interface{} {
return l
}

type lgwr struct {
l log.Logger
Expand Down
6 changes: 5 additions & 1 deletion util/liblog/liblog_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"fmt"
"testing"

"github.com/cometbft/cometbft/libs/log"
"cosmossdk.io/log"
"github.com/palomachain/paloma/util/liblog"
"github.com/stretchr/testify/assert"
)
Expand All @@ -14,6 +14,10 @@ type mock struct {
args []interface{}
}

func (m *mock) Impl() interface{} {
return m
}

func (m *mock) Debug(msg string, keyvals ...interface{}) {
m.invocations = append(m.invocations, "Debug")
m.args = append(m.args, msg)
Expand Down
2 changes: 1 addition & 1 deletion x/paloma/ante.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ func NewVerifyAuthorisedSignatureDecorator(fk types.FeegrantKeeper) VerifyAuthor
// AnteHandle verifies that the message is signed by at least one signature that has
// active fee grant from the creator address, IF the message contains metadata.
func (d VerifyAuthorisedSignatureDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler) (sdk.Context, error) {
if simulate || ctx.IsCheckTx() {
if simulate {
return next(ctx, tx, simulate)
}

Expand Down

0 comments on commit 18a2d0e

Please sign in to comment.