Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
make private and readonly things private and readonly
Browse files Browse the repository at this point in the history
  • Loading branch information
davidmurdoch committed Sep 24, 2020
1 parent 430907c commit fbdf45c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/chains/ethereum/src/components/transaction-pool.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ export default class TransactionPool extends Emittery.Typed<{}, "drain"> {
/**
* Minimum price bump percentage to replace an already existing transaction (nonce)
*/
public priceBump: bigint = 10n;
#priceBump: bigint = 10n;

#blockchain: Blockchain;
constructor(options: EthereumInternalOptions["miner"], blockchain: Blockchain) {
super();
this.#blockchain = blockchain;
this.#options = options;
}
public executables: Map<string, utils.Heap<Transaction>> = new Map();
#origins: Map<string, utils.Heap<Transaction>> = new Map();
#accountPromises = new Map<string, PromiseLike<Account>>();
public readonly executables: Map<string, utils.Heap<Transaction>> = new Map();
readonly #origins: Map<string, utils.Heap<Transaction>> = new Map();
readonly #accountPromises = new Map<string, PromiseLike<Account>>();

/**
* Inserts a transaction into the pending queue, if executable, or future pool
Expand Down Expand Up @@ -77,7 +77,7 @@ export default class TransactionPool extends Emittery.Typed<{}, "drain"> {
// executables queue already. Replace the matching transaction or throw this
// new transaction away as neccessary.
const pendingArray = executableOriginTransactions.array;
const priceBump = this.priceBump;
const priceBump = this.#priceBump;
const newGasPrice = Quantity.from(transaction.gasPrice).toBigInt();
// Notice: we're iterating over the raw heap array, which isn't
// neccessarily sorted
Expand Down

0 comments on commit fbdf45c

Please sign in to comment.