diff --git a/routes/controller.go b/routes/controller.go index db08ba0..b6e4c36 100644 --- a/routes/controller.go +++ b/routes/controller.go @@ -198,18 +198,6 @@ func handleGetJob(c *gin.Context, req ControllerBody, workerState *worker.State) return } - if workerState.CheckLimitExceeded() { - log.Warnf("[CONTROLLER] [%s] GetJob would exceed soft limits - DISABLED ACCOUNT: [%s]", req.Uuid, req.Username) - accountManager.MarkDisabled(req.Username) - workerState.ResetUsername() - respondWithData(c, &map[string]any{ - "action": SwitchAccount.String(), - "min_level": 30, - "max_level": 40, - }) - return - } - if workerState.AreaId == math.MaxInt { task := map[string]any{ "action": ScanPokemon.String(), diff --git a/routes/raw.go b/routes/raw.go index 17180cd..ce7a9ad 100644 --- a/routes/raw.go +++ b/routes/raw.go @@ -100,6 +100,11 @@ func Raw(c *gin.Context) { log.Debugf("[RAW] [%s] Account '%s' updated with information from Game", res.Uuid, res.Username) } } + if ws.CheckLimitExceeded() { + log.Warnf("[RAW] [%s] GetJob would exceed soft limits - DISABLED ACCOUNT: [%s]", res.Uuid, res.Username) + accountManager.MarkDisabled(res.Username) + + } }() }