diff options
author | gumi <git@gumi.ca> | 2020-02-14 12:18:00 -0500 |
---|---|---|
committer | gumi <git@gumi.ca> | 2020-03-02 15:37:17 -0500 |
commit | 2c25f53ddf418bdedd94c6142b03c80e49fc584d (patch) | |
tree | c15c45c16b7b649fb267241ffe0fe90aacf6fae5 /src/routers/tmwa/index.js | |
parent | 872288426090839f2f23e60187a58ee51d6fe4ea (diff) | |
download | api-2c25f53ddf418bdedd94c6142b03c80e49fc584d.tar.gz api-2c25f53ddf418bdedd94c6142b03c80e49fc584d.tar.bz2 api-2c25f53ddf418bdedd94c6142b03c80e49fc584d.tar.xz api-2c25f53ddf418bdedd94c6142b03c80e49fc584d.zip |
add support for Vault + major refactor
Diffstat (limited to 'src/routers/tmwa/index.js')
-rw-r--r-- | src/routers/tmwa/index.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/routers/tmwa/index.js b/src/routers/tmwa/index.js index f3eeb72..f89c6bd 100644 --- a/src/routers/tmwa/index.js +++ b/src/routers/tmwa/index.js @@ -7,7 +7,7 @@ const middlewares = { }; module.exports = exports = class TMWA { - constructor(config, api, challenge, rate_limit) { + constructor(config, api, challenge) { // XXX: having to pass a reference to `api` is weird, we should instead // store config in this.config and make the middlewares (somehow) // access this.config. the problem is that we can't pass arguments @@ -22,7 +22,7 @@ module.exports = exports = class TMWA { this.router.get("/server", middlewares.server); - this.router.all("/account", rate_limit, challenge); // flood limit + captcha + this.router.all("/account", challenge); // require captcha this.router.all("/account", express.json(), middlewares.account); tmwa_poll(this); // first heartbeat |