Skip to content

Commit acb2abe

Browse files
authored
fix: Add workaround for incorrect handling of maxTotalChargeUsd (#360)
* fix: Add workaround for incorrect handling of maxTotalChargeUsd * lint
1 parent 0d65d96 commit acb2abe

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/apify/src/charging.ts

+3
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ export class ChargingManager {
2727

2828
constructor(configuration: Configuration, apifyClient: ApifyClient) {
2929
this.maxTotalChargeUsd = configuration.get('maxTotalChargeUsd') ?? Infinity;
30+
if (typeof this.maxTotalChargeUsd === 'string') { // TODO workaround for incorrect Configuration class behavior
31+
this.maxTotalChargeUsd = Infinity;
32+
}
3033
this.isAtHome = configuration.get('isAtHome');
3134
this.actorRunId = configuration.get('actorRunId');
3235
this.purgeChargingLogDataset = configuration.get('purgeOnStart');

0 commit comments

Comments
 (0)