Compare commits
1 commit
master
...
dependabot
Author | SHA1 | Date | |
---|---|---|---|
033c442007 |
14
.eslintrc.js
14
.eslintrc.js
|
@ -4,18 +4,4 @@ module.exports = {
|
|||
parser: '@typescript-eslint/parser',
|
||||
plugins: ['@typescript-eslint'],
|
||||
root: true,
|
||||
rules: {
|
||||
"@typescript-eslint/no-unused-vars": [
|
||||
"error",
|
||||
{
|
||||
"args": "all",
|
||||
"argsIgnorePattern": "^_",
|
||||
"caughtErrors": "all",
|
||||
"caughtErrorsIgnorePattern": "^_",
|
||||
"destructuredArrayIgnorePattern": "^_",
|
||||
"varsIgnorePattern": "^_",
|
||||
"ignoreRestSiblings": true
|
||||
}
|
||||
]
|
||||
}
|
||||
};
|
||||
|
|
12
flake.lock
12
flake.lock
|
@ -5,11 +5,11 @@
|
|||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1709126324,
|
||||
"narHash": "sha256-q6EQdSeUZOG26WelxqkmR7kArjgWCdw5sfJVHPH/7j8=",
|
||||
"lastModified": 1701680307,
|
||||
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "d465f4819400de7c8d874d50b982301f28a84605",
|
||||
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -20,11 +20,11 @@
|
|||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1709677081,
|
||||
"narHash": "sha256-tix36Y7u0rkn6mTm0lA45b45oab2cFLqAzDbJxeXS+c=",
|
||||
"lastModified": 1703992652,
|
||||
"narHash": "sha256-C0o8AUyu8xYgJ36kOxJfXIroy9if/G6aJbNOpA5W0+M=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "880992dcc006a5e00dd0591446fdf723e6a51a64",
|
||||
"rev": "32f63574c85fbc80e4ba1fbb932cde9619bad25e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
@ -14,6 +14,8 @@
|
|||
|
||||
src = ./.;
|
||||
|
||||
npmBuildScript = "release";
|
||||
npmBuildFlags = [ "--" "--outDir" "dist" ];
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
cp -r dist $out/
|
||||
|
@ -24,7 +26,7 @@
|
|||
runHook postInstall
|
||||
'';
|
||||
|
||||
npmDepsHash = "sha256-fqvUE5/M2VyIL5CyDEuUGye27e9fJJImMYL1wwZNFPg=";
|
||||
npmDepsHash = "sha256-Wo4dGsUAZwXbkuWwTKNA5kv4ZUnekdKm/TagP4Q4Ds8=";
|
||||
};
|
||||
};
|
||||
in flake-utils.lib.eachDefaultSystem (system:
|
||||
|
@ -43,3 +45,4 @@
|
|||
formatter = pkgs.nixfmt;
|
||||
});
|
||||
}
|
||||
|
||||
|
|
669
package-lock.json
generated
669
package-lock.json
generated
File diff suppressed because it is too large
Load diff
23
package.json
23
package.json
|
@ -13,30 +13,31 @@
|
|||
"format": "prettier -w .",
|
||||
"lint": "eslint --fix .",
|
||||
"build": "tsc",
|
||||
"prestart": "npm run build",
|
||||
"prestart": "npm build",
|
||||
"start": "node .",
|
||||
"dev": "npm run build && npm run start",
|
||||
"dev": "npm build && npm start",
|
||||
"serve": "nodemon",
|
||||
"prepack": "npm run build"
|
||||
"prepack": "npm build",
|
||||
"release": "tsc"
|
||||
},
|
||||
"dependencies": {
|
||||
"ejs": "^3.1.9",
|
||||
"express": "~4.18.2",
|
||||
"express-actuator": "^1.8.4",
|
||||
"redis": "^4.6.13",
|
||||
"winston": "^3.12.0"
|
||||
"redis": "^4.6.9",
|
||||
"winston": "^3.10.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@tsconfig/recommended": "^1.0.3",
|
||||
"@types/express": "^4.17.17",
|
||||
"@types/express-actuator": "^1.8.0",
|
||||
"@types/node": "^18.16.1",
|
||||
"@typescript-eslint/eslint-plugin": "^7.1.0",
|
||||
"@typescript-eslint/parser": "^7.1.0",
|
||||
"eslint": "^8.57.0",
|
||||
"eslint-config-prettier": "^9.1.0",
|
||||
"nodemon": "^3.1.0",
|
||||
"@typescript-eslint/eslint-plugin": "^5.62.0",
|
||||
"@typescript-eslint/parser": "^5.62.0",
|
||||
"eslint": "^8.49.0",
|
||||
"eslint-config-prettier": "^9.0.0",
|
||||
"nodemon": "^3.0.1",
|
||||
"prettier": "3.2.5",
|
||||
"typescript": "^5.4.0"
|
||||
"typescript": "^5.2.2"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@ import { redisClient } from "./app";
|
|||
|
||||
const router = Router();
|
||||
|
||||
router.get("/", async (_req, res, _next) => {
|
||||
router.get("/", async (req, res, next) => {
|
||||
if (!redisClient.isOpen) {
|
||||
await redisClient.connect();
|
||||
}
|
||||
|
@ -17,7 +17,7 @@ router.get("/", async (_req, res, _next) => {
|
|||
return res.send(result);
|
||||
});
|
||||
|
||||
router.get("/public_games", async (req, res, _next) => {
|
||||
router.get("/public_games", async (req, res, next) => {
|
||||
let gameFilter = "";
|
||||
|
||||
if (req.query.titleid != null && (req.query.titleid as string)?.length > 0) {
|
||||
|
|
|
@ -2,11 +2,7 @@ import { Request, Response, NextFunction } from "express";
|
|||
import { logger } from "./app";
|
||||
import { loggerDefaultMetadata } from "./utils";
|
||||
|
||||
export function requestLogger(
|
||||
req: Request,
|
||||
_res: Response,
|
||||
next: NextFunction
|
||||
) {
|
||||
export function requestLogger(req: Request, res: Response, next: NextFunction) {
|
||||
logger.debug("Incoming request.", loggerDefaultMetadata(req));
|
||||
next();
|
||||
}
|
||||
|
@ -14,7 +10,7 @@ export function requestLogger(
|
|||
export function errorLogger(
|
||||
err: Error,
|
||||
req: Request,
|
||||
_res: Response,
|
||||
res: Response,
|
||||
next: NextFunction
|
||||
) {
|
||||
logger.error(err.message, {
|
||||
|
|
Loading…
Reference in a new issue