basic session management completed #11

Merged
AKCore merged 9 commits from main into main 2023-06-03 19:24:57 -07:00
11 changed files with 213 additions and 9 deletions

View File

@ -1,6 +1,8 @@
import { RequestHandler } from "express"; import { RequestHandler } from "express";
import { deleteSession } from "@/src/managers/sessionManager";
const deleteSessionController: RequestHandler = (_req, res) => { const deleteSessionController: RequestHandler = (_req, res) => {
deleteSession(_req.query.sessionId as string);
res.sendStatus(200); res.sendStatus(200);
}; };

View File

@ -1,9 +1,28 @@
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
import { RequestHandler } from "express"; import { RequestHandler } from "express";
import { getSession } from "@/src/managers/sessionManager";
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
const findSessionsController: RequestHandler = (_req, res) => { const findSessionsController: RequestHandler = (_req, res) => {
console.log("FindSession Request:", JSON.parse(_req.body)); console.log("FindSession Request:", JSON.parse(_req.body));
let req = JSON.parse(_req.body);
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
if (req.id != undefined) {
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
console.log("Found ID");
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
let session = getSession(req.id);
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
res.json({ sessionId: { $oid: "64768f104722f795300c9fc0" }, rewardSeed: 5867309943877621023 }); if (session) res.json({ queryId: req.queryId, Sessions: session });
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
else res.json({});
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
} else if (req.originalSessionId != undefined) {
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
console.log("Found OriginalSessionID");
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
let session = getSession(req.originalSessionId);
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
if (session) res.json({ queryId: req.queryId, Sessions: session });
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
else res.json({});
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
} else {
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
console.log("Found SessionRequest");
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
let session = getSession(_req.body);
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
if (session) res.json({ queryId: req.queryId, Sessions: session });
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
else res.json({});
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
}
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
}; };
export { findSessionsController }; export { findSessionsController };

AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:57:00 -07:00 (Migrated from github.com)
Review

pls add curly braces everywhere

pls add curly braces everywhere
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AngeloTadeucci commented 2023-06-03 17:58:10 -07:00 (Migrated from github.com)
Review

useless case, already handled above. also would suggest removing the else and using a return

useless case, already handled above. also would suggest removing the else and using a return
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code
AKCore commented 2023-06-03 18:09:50 -07:00 (Migrated from github.com)
Review

Fixed this code

Fixed this code

View File

@ -1,7 +1,13 @@
import { RequestHandler } from "express"; import { RequestHandler } from "express";
const getNewRewardSeedController: RequestHandler = (_req, res) => { const getNewRewardSeedController: RequestHandler = (_req, res) => {
res.json({ rewardSeed: 5867309943877621023 }); res.json({ rewardSeed: generateRewardSeed() });
}; };
function generateRewardSeed(): number {
const min = -Number.MAX_SAFE_INTEGER;
AngeloTadeucci commented 2023-06-03 17:58:28 -07:00 (Migrated from github.com)
Review

not being used?

not being used?
AKCore commented 2023-06-03 18:05:03 -07:00 (Migrated from github.com)
Review

Just for the moment. it is going to be used for seed generation I removed it while testing because i thought it was breaking my join requests

Just for the moment. it is going to be used for seed generation I removed it while testing because i thought it was breaking my join requests
const max = Number.MAX_SAFE_INTEGER;
return Math.floor(Math.random() * (max - min + 1)) + min;
}
export { getNewRewardSeedController }; export { getNewRewardSeedController };

View File

@ -1,9 +1,12 @@
import { RequestHandler } from "express"; import { RequestHandler } from "express";
import { createNewSession } from "@/src/managers/sessionManager";
const hostSessionController: RequestHandler = (_req, res) => { const hostSessionController: RequestHandler = (_req, res) => {
console.log("HostSession Request:", JSON.parse(_req.body)); console.log("HostSession Request:", JSON.parse(_req.body));
let session = createNewSession(JSON.parse(_req.body), _req.query.accountId as string);
console.log("New Session Created: ", session);
res.json({ sessionId: { $oid: "64768f104722f795300c9fc0" }, rewardSeed: 5867309943877621023 }); res.json({ sessionId: { $oid: session.sessionId }, rewardSeed: 99999999 });
}; };
export { hostSessionController }; export { hostSessionController };

View File

@ -0,0 +1,11 @@
import { RequestHandler } from "express";
import { getSessionByID } from "@/src/managers/sessionManager";
const joinSessionController: RequestHandler = (_req, res) => {
console.log("JoinSession Request:", JSON.parse(_req.body));
let req = JSON.parse(_req.body);
let session = getSessionByID(req.sessionIds[0]);
res.json({ rewardSeed: session?.rewardSeed, sessionId: { $oid: session?.sessionId } });
};
export { joinSessionController };

View File

@ -1,12 +1,11 @@
import { RequestHandler } from "express"; import { RequestHandler } from "express";
const logoutController: RequestHandler = (_req, res) => { const logoutController: RequestHandler = (_req, res) => {
const data = Buffer.from([0x31]);
res.writeHead(200, { res.writeHead(200, {
"Content-Type": "text/html", "Content-Type": "text/html",
"Content-Length": data.length "Content-Length": 1
}); });
res.end(data); res.end("1");
}; };
export { logoutController }; export { logoutController };

View File

@ -1,11 +1,13 @@
import { RequestHandler } from "express"; import { RequestHandler } from "express";
import { updateSession } from "@/src/managers/sessionManager";
const updateSessionGetController: RequestHandler = (_req, res) => { const updateSessionGetController: RequestHandler = (_req, res) => {
res.json({}); res.json({});
}; };
const updateSessionPostController: RequestHandler = (_req, res) => { const updateSessionPostController: RequestHandler = (_req, res) => {
console.log("UpdateSessions POST Request:", JSON.parse(_req.body)); console.log("UpdateSessions POST Request:", JSON.parse(_req.body));
console.log("ReqID:", _req.query.sessionId as string);
res.json({ hasStarted: true }); updateSession(_req.query.sessionId as string, _req.body);
res.json({});
}; };
export { updateSessionGetController, updateSessionPostController }; export { updateSessionGetController, updateSessionPostController };

View File

@ -0,0 +1,132 @@
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
import { Session, FindSessionRequest } from "@/src/types/session";
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const sessions: Session[] = [];
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
function createNewSession(sessionData: Session, Creator: string): Session {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const sessionId = getNewSessionID();
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const newSession: Session = {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
sessionId,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
creatorId: Creator,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
maxPlayers: sessionData.maxPlayers || 4,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
minPlayers: sessionData.minPlayers || 1,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
privateSlots: sessionData.privateSlots || 0,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
scoreLimit: sessionData.scoreLimit || 15,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
timeLimit: sessionData.timeLimit || 900,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
gameModeId: sessionData.gameModeId || 0,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
eloRating: sessionData.eloRating || 3,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
regionId: sessionData.regionId || 3,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
difficulty: sessionData.difficulty || 0,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
hasStarted: sessionData.hasStarted || false,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
enableVoice: sessionData.enableVoice || true,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
matchType: sessionData.matchType || "NORMAL",
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
maps: sessionData.maps || [],
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
originalSessionId: sessionData.originalSessionId || "",
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
customSettings: sessionData.customSettings || "",
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
rewardSeed: sessionData.rewardSeed || -1,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
guildId: sessionData.guildId || "",
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
buildId: sessionData.buildId || 4920386201513015989,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
platform: sessionData.platform || 0,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
xplatform: sessionData.xplatform || true,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
freePublic: sessionData.freePublic || 3,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
freePrivate: sessionData.freePrivate || 0,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
fullReset: 0
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
};
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
sessions.push(newSession);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return newSession;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
function getAllSessions(): Session[] {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return sessions;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
function getSessionByID(sessionId: string): Session | undefined {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return sessions.find(session => session.sessionId === sessionId);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
function getSession(sessionIdOrRequest: string | FindSessionRequest): any[] {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
if (typeof sessionIdOrRequest === "string") {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const session = sessions.find(session => session.sessionId === sessionIdOrRequest);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
if (session) {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
console.log("Found Sessions:", session);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return [
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
{
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
createdBy: session.creatorId,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
id: session.sessionId
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
];
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return [];
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const request = sessionIdOrRequest as FindSessionRequest;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const matchingSessions = sessions.filter(session => {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
for (const key in request) {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
if (key !== "eloRating" && key !== "queryId" && request[key] !== session[key as keyof Session]) {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return false;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
console.log("Found Matching Sessions:", matchingSessions);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return true;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
});
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return matchingSessions.map(session => ({
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
createdBy: session.creatorId,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
id: session.sessionId
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}));
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
function getSessionByCreatorID(creatorId: string): Session | undefined {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return sessions.find(session => session.creatorId === creatorId);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
function getNewSessionID(): string {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const characters = "0123456789abcdef";
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const maxAttempts = 100;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
let sessionId = "";
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
for (let attempt = 0; attempt < maxAttempts; attempt++) {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
sessionId = "64";
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
for (let i = 0; i < 22; i++) {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const randomIndex = Math.floor(Math.random() * characters.length);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
sessionId += characters[randomIndex];
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
if (!sessions.some(session => session.sessionId === sessionId)) {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return sessionId;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:06 -07:00 (Migrated from github.com)
Review

could remove this for loop and just use some type of UUID

could remove this for loop and just use some type of UUID
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
OrdisPrime commented 2023-06-03 18:08:36 -07:00 (Migrated from github.com)
Review

uuid package is really good, I can help to set it up.

uuid package is really good, I can help to set it up.
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
throw new Error("Failed to generate a unique session ID");
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
function updateSession(sessionId: string, sessionData: string): boolean {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const session = sessions.find(session => session.sessionId === sessionId);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
if (!session) return false;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
try {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const updatedData = JSON.parse(sessionData);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
Object.assign(session, updatedData);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return true;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
} catch (error) {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
console.error("Invalid JSON string for session update.");
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return false;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
function deleteSession(sessionId: string): boolean {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
const index = sessions.findIndex(session => session.sessionId === sessionId);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
if (index !== -1) {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
sessions.splice(index, 1);
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return true;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
return false;
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
}
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
export {
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
createNewSession,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
getAllSessions,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
getSessionByID,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
getSessionByCreatorID,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
getNewSessionID,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
updateSession,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
deleteSession,
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
getSession
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.
};
AngeloTadeucci commented 2023-06-03 17:59:47 -07:00 (Migrated from github.com)
Review

move interface to another file like /types/session.ts

move interface to another file like /types/session.ts
AngeloTadeucci commented 2023-06-03 18:00:43 -07:00 (Migrated from github.com)
Review

this is basically an 'any' type, could move it to another file an call it "LooseObject"

this is basically an 'any' type, could move it to another file an call it "LooseObject"
AngeloTadeucci commented 2023-06-03 18:01:52 -07:00 (Migrated from github.com)
Review

redundant else

redundant else
AngeloTadeucci commented 2023-06-03 18:03:43 -07:00 (Migrated from github.com)
Review

invert if

invert if
AKCore commented 2023-06-03 18:12:59 -07:00 (Migrated from github.com)
Review

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest

not redundant, its a flip in the case depending on if the input is a string or a findSessionRequest
AngeloTadeucci commented 2023-06-03 18:14:44 -07:00 (Migrated from github.com)
Review

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

i mean only the keyword is redundant. since you are returning in all cases inside the first if block.

View File

@ -27,6 +27,8 @@ import { surveysController } from "@/src/controllers/api/surveysController";
import { updateChallengeProgressController } from "@/src/controllers/api/updateChallengeProgressController"; import { updateChallengeProgressController } from "@/src/controllers/api/updateChallengeProgressController";
import { updateSessionGetController, updateSessionPostController } from "@/src/controllers/api/updateSessionController"; import { updateSessionGetController, updateSessionPostController } from "@/src/controllers/api/updateSessionController";
import { viewController } from "@/src/controllers/api/viewController"; import { viewController } from "@/src/controllers/api/viewController";
import { joinSessionController } from "@/src/controllers/api/joinSessionController";
import express from "express"; import express from "express";
const apiRouter = express.Router(); const apiRouter = express.Router();
@ -65,4 +67,5 @@ apiRouter.post("/updateSession.php", updateSessionPostController);
apiRouter.post("/missionInventoryUpdate.php", missionInventoryUpdateController); apiRouter.post("/missionInventoryUpdate.php", missionInventoryUpdateController);
apiRouter.post("/genericUpdate.php", genericUpdateController); apiRouter.post("/genericUpdate.php", genericUpdateController);
apiRouter.post("/rerollRandomMod.php", rerollRandomModController); apiRouter.post("/rerollRandomMod.php", rerollRandomModController);
apiRouter.post("/joinSession.php", joinSessionController);
export { apiRouter }; export { apiRouter };

27
src/types/session.ts Normal file
View File

@ -0,0 +1,27 @@
export interface Session {
sessionId: string;
creatorId: string;
maxPlayers: number;
minPlayers: number;
privateSlots: number;
scoreLimit: number;
timeLimit: number;
gameModeId: number;
eloRating: number;
regionId: number;
difficulty: number;
hasStarted: boolean;
enableVoice: boolean;
matchType: string;
maps: string[];
originalSessionId: string;
customSettings: string;
rewardSeed: number;
guildId: string;
buildId: number;
platform: number;
xplatform: boolean;
freePublic: number;
freePrivate: number;
fullReset: number;
}

View File

@ -24,7 +24,7 @@ export const platformCDNs = [
export const Nonce = 1231231233; export const Nonce = 1231231233;
export const NRS = ["104.237.145.11", "139.144.69.73", "170.187.231.80", "45.33.58.33", "85.159.214.213"]; export const NRS = ["localhost"];
export const DTLS = 99; export const DTLS = 99;