basic session management completed #11

Merged
AKCore merged 9 commits from main into main 2023-06-03 19:24:57 -07:00
AKCore commented 2023-06-03 17:51:42 -07:00 (Migrated from github.com)

Session Management is very early but working as expected so far.

Session Management is very early but working as expected so far.
AngeloTadeucci (Migrated from github.com) requested changes 2023-06-03 18:03:52 -07:00
AngeloTadeucci (Migrated from github.com) commented 2023-06-03 17:57:00 -07:00

pls add curly braces everywhere

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

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
@ -5,2 +5,4 @@
};
function generateRewardSeed(): number {
const min = -Number.MAX_SAFE_INTEGER;
AngeloTadeucci (Migrated from github.com) commented 2023-06-03 17:58:28 -07:00

not being used?

not being used?
AngeloTadeucci (Migrated from github.com) commented 2023-06-03 17:59:47 -07:00

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

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

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 (Migrated from github.com) commented 2023-06-03 18:01:52 -07:00

redundant else

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

invert if

invert if
@ -0,0 +93,4 @@
if (!sessions.some(session => session.sessionId === sessionId)) {
return sessionId;
}
}
AngeloTadeucci (Migrated from github.com) commented 2023-06-03 18:03:06 -07:00

could remove this for loop and just use some type of UUID

could remove this for loop and just use some type of UUID
AKCore (Migrated from github.com) reviewed 2023-06-03 18:05:03 -07:00
@ -5,2 +5,4 @@
};
function generateRewardSeed(): number {
const min = -Number.MAX_SAFE_INTEGER;
AKCore (Migrated from github.com) commented 2023-06-03 18:05:03 -07:00

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
OrdisPrime (Migrated from github.com) reviewed 2023-06-03 18:08:36 -07:00
@ -0,0 +93,4 @@
if (!sessions.some(session => session.sessionId === sessionId)) {
return sessionId;
}
}
OrdisPrime (Migrated from github.com) commented 2023-06-03 18:08:36 -07:00

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 (Migrated from github.com) reviewed 2023-06-03 18:09:50 -07:00
AKCore (Migrated from github.com) commented 2023-06-03 18:09:50 -07:00

Fixed this code

Fixed this code
AKCore (Migrated from github.com) reviewed 2023-06-03 18:12:59 -07:00
AKCore (Migrated from github.com) commented 2023-06-03 18:12:59 -07:00

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 (Migrated from github.com) reviewed 2023-06-03 18:15:27 -07:00
AngeloTadeucci (Migrated from github.com) commented 2023-06-03 18:14:44 -07:00

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 (Migrated from github.com) approved these changes 2023-06-03 19:00:44 -07:00
Sign in to join this conversation.
No description provided.