Skip to content

Commit

Permalink
chore: fixup
Browse files Browse the repository at this point in the history
Signed-off-by: moul <94029+moul@users.noreply.github.com>
  • Loading branch information
moul committed Oct 21, 2024
1 parent 581ef26 commit a39d172
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gno.land/pkg/sdk/vm/gas_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ func TestAddPkgDeliverTx(t *testing.T) {
assert.True(t, res.IsOK())

// NOTE: let's try to keep this bellow 100_000 :)
assert.Equal(t, int64(92825), gasDeliver)
assert.Equal(t, int64(93825), gasDeliver)
}

// Enough gas for a failed transaction.
Expand Down
5 changes: 4 additions & 1 deletion gno.land/pkg/sdk/vm/keeper.go
Original file line number Diff line number Diff line change
Expand Up @@ -229,9 +229,12 @@ func (vm *VMKeeper) getGnoTransactionStore(ctx sdk.Context) gno.TransactionStore
// Namespace can be either a user or crypto address.
var reNamespace = regexp.MustCompile(`^gno.land/(?:r|p)/([\.~_a-zA-Z0-9]+)`)

const sysUsersPkgParamKey = "vm/gno.land/r/sys/params.string"

// checkNamespacePermission check if the user as given has correct permssion to on the given pkg path
func (vm *VMKeeper) checkNamespacePermission(ctx sdk.Context, creator crypto.Address, pkgPath string) error {
const sysUsersPkg = "gno.land/r/sys/users"
var sysUsersPkg = "gno.land/r/sys/users"
vm.prmk.GetIfExists(ctx, sysUsersPkgParamKey, &sysUsersPkg)

store := vm.getGnoTransactionStore(ctx)

Expand Down

0 comments on commit a39d172

Please sign in to comment.