Skip to content

Commit

Permalink
Remove old obsolete hack on Tezos gas limit
Browse files Browse the repository at this point in the history
  • Loading branch information
hakim-adamik committed Sep 27, 2023
1 parent e00647b commit 4ed2616
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 35 deletions.
17 changes: 0 additions & 17 deletions libs/ledger-live-common/src/__tests__/modulo.ts

This file was deleted.

11 changes: 0 additions & 11 deletions libs/ledger-live-common/src/families/tezos/signOperation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ import type { OperationType, SignOperationFnSignature } from "@ledgerhq/types-li
import { withDevice } from "../../hw/deviceAccess";
import { getEnv } from "@ledgerhq/live-env";
import { FeeNotLoaded } from "@ledgerhq/errors";
import { upperModulo } from "../../modulo";
import BigNumber from "bignumber.js";
import { encodeOperationId } from "@ledgerhq/coin-framework/operation";

export const signOperation: SignOperationFnSignature<Transaction> = ({
Expand Down Expand Up @@ -54,15 +52,6 @@ export const signOperation: SignOperationFnSignature<Transaction> = ({
gasLimit: transaction.gasLimit?.toNumber() || 0,
};

if (["delegate", "undelegate"].includes(transaction.mode)) {
// https://ledgerhq.atlassian.net/browse/LL-8821
params.gasLimit = upperModulo(
transaction.gasLimit || new BigNumber(0),
new BigNumber(136),
new BigNumber(1000),
).toNumber();
}

switch (transaction.mode) {
case "send":
res = await tezos.contract.transfer({
Expand Down
7 changes: 0 additions & 7 deletions libs/ledger-live-common/src/modulo.ts

This file was deleted.

0 comments on commit 4ed2616

Please sign in to comment.