Prevent attempting to authenticate more than four times per hour

This only affects scripts - running this nxapi command in a terminal and the Electron app will ignore this limit.

https://github.com/samuelthomas2774/nxapi/issues/9
This commit is contained in:
Samuel Elliott
2022-07-27 15:48:19 +01:00
parent d3e5a88625
commit e12bb364a7
32 changed files with 109 additions and 48 deletions

View File

@@ -4,7 +4,7 @@ import { ActiveEvent, Announcements, CurrentUser, Event, Friend, Presence, Prese
import { ErrorResponse } from './util.js';
import CoralApi from './coral.js';
import { NintendoAccountUser } from './na.js';
import { SavedToken } from '../common/auth/nso.js';
import { SavedToken } from '../common/auth/coral.js';
import { timeoutSignal } from '../util/misc.js';
import { getAdditionalUserAgents, getUserAgent } from '../util/useragent.js';