Skip to content

Commit

Permalink
Fix gas calculation (#1567) (#1570)
Browse files Browse the repository at this point in the history
(cherry picked from commit bfaf589)

Co-authored-by: Christoph Otter <chris@confio.gmbh>
  • Loading branch information
mergify[bot] and chipshort authored Aug 24, 2023
1 parent aae393e commit 390fda7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion x/wasm/keeper/query_plugins.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func (q QueryHandler) Query(request wasmvmtypes.QueryRequest, gasLimit uint64) (
}

func (q QueryHandler) GasConsumed() uint64 {
return q.Ctx.GasMeter().GasConsumed()
return q.gasRegister.ToWasmVMGas(q.Ctx.GasMeter().GasConsumed())
}

type CustomQuerier func(ctx sdk.Context, request json.RawMessage) ([]byte, error)
Expand Down

0 comments on commit 390fda7

Please sign in to comment.