Remove "Infinity" usage
This commit is contained in:
@@ -49,7 +49,7 @@ export class Queue {
|
||||
fn: () => PromiseLike<T> | T,
|
||||
priority: QueuePriority = Priority.NORMAL,
|
||||
): { key: string; promise: Promise<T> } {
|
||||
this.counter = (this.counter + 1) % Infinity;
|
||||
this.counter = (this.counter + 1) % Number.MAX_SAFE_INTEGER;
|
||||
const actualKey = `${key}_${this.counter}`;
|
||||
|
||||
this.pendingKeyToPriorityMap.set(actualKey, priority);
|
||||
|
||||
@@ -277,7 +277,7 @@ export const TrackerActiveCard = ({
|
||||
settingValue={`${trackRecord.lastChapterRead}/${trackRecord.totalChapters}`}
|
||||
value={trackRecord.lastChapterRead}
|
||||
minValue={0}
|
||||
maxValue={Infinity}
|
||||
maxValue={Number.MAX_SAFE_INTEGER}
|
||||
valueUnit=""
|
||||
handleUpdate={(lastChapterRead) => updateTrackerBind({ lastChapterRead })}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user