@@ -49,11 +49,11 @@ export const createUser = async (email: string, password: string, fullName: stri
|
||||
}
|
||||
|
||||
return {
|
||||
session_id: sessionId,
|
||||
user_id: userId,
|
||||
session_key: sessionKey,
|
||||
session_key_hash: 'HIDDEN',
|
||||
last_ip: ip
|
||||
sessionId: sessionId,
|
||||
userId: userId,
|
||||
sessionKey: sessionKey,
|
||||
sessionKeyHash: 'HIDDEN',
|
||||
lastIP: ip
|
||||
};
|
||||
} catch (err) {
|
||||
throw err;
|
||||
@@ -102,11 +102,11 @@ export const login = async (email: string, password: string, ip: string): Promis
|
||||
}
|
||||
|
||||
return {
|
||||
session_id: sessionId,
|
||||
user_id: userId,
|
||||
session_key: sessionKey,
|
||||
session_key_hash: 'HIDDEN',
|
||||
last_ip: ip
|
||||
sessionId: sessionId,
|
||||
userId: userId,
|
||||
sessionKey: sessionKey,
|
||||
sessionKeyHash: 'HIDDEN',
|
||||
lastIP: ip
|
||||
};
|
||||
} catch (err) {
|
||||
throw err;
|
||||
@@ -167,11 +167,11 @@ export const checkSession = async (sessionId: string, sessionKey: string, ip: st
|
||||
|
||||
// Everything is fine, return user information
|
||||
return {
|
||||
user_id: userId,
|
||||
userId: userId,
|
||||
email: email,
|
||||
password_hash: 'HIDDEN',
|
||||
full_name: fullName,
|
||||
is_active: is_active
|
||||
passwordHash: 'HIDDEN',
|
||||
fullName: fullName,
|
||||
isActive: is_active
|
||||
};
|
||||
} catch (err) {
|
||||
throw err;
|
||||
|
||||
Reference in New Issue
Block a user