-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bc837db
commit b4330f5
Showing
6 changed files
with
104 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
function rateControlMiddleware(log, redisConnection){ | ||
this.middleware = function(req, res, next){ | ||
next(); | ||
} | ||
} | ||
|
||
export default function(log, redisConnection){ | ||
try{ | ||
let middleware = new rateControlMiddleware(log, redisConnection).middleware; | ||
log("log", "RateControl", "Rate control middleware instance created."); | ||
return middleware; | ||
}catch(err){ | ||
log("error", "RateControl", "Rate control middleware failed to load."); | ||
log("error", "RateControl", err); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
function SessionCheckMiddleware(log, redisConnection){ | ||
this.middleware = function(req, res, next){ | ||
next(); | ||
} | ||
} | ||
|
||
export default function(log, redisConnection){ | ||
try{ | ||
let middleware = new SessionCheckMiddleware(log, redisConnection).middleware; | ||
log("log", "SessionCheck", "Session check middleware instance created."); | ||
return middleware; | ||
}catch(err){ | ||
log("error", "SessionCheck", "Session check middleware failed to load."); | ||
log("error", "SessionCheck", err); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.