mirror of
https://github.com/r-ca/kidshift-be.git
synced 2024-10-25 16:14:02 +00:00
revert
This commit is contained in:
parent
07efcde405
commit
549993e4fe
|
@ -8,7 +8,7 @@ import { TokenResponse } from "@src/models/Token";
|
|||
const logger = new Logger();
|
||||
logger.setTag('authService');
|
||||
|
||||
async function registUser(email: string, password: string, homeGroupId?: string): Promise<TokenResponse> {
|
||||
async function registUser(email: string, password: string, homeGroupId?: string): Promise<String> {
|
||||
|
||||
const hashedPassword = bcrypt.hashSync(password, 10);
|
||||
|
||||
|
@ -41,10 +41,7 @@ async function registUser(email: string, password: string, homeGroupId?: string)
|
|||
});
|
||||
|
||||
const user = await registUser;
|
||||
const response: TokenResponse = {
|
||||
accessToken: await issueTokenByUserId(user.id)
|
||||
};
|
||||
return Promise.resolve(response)
|
||||
return issueTokenByUserId(user.id);
|
||||
}
|
||||
|
||||
async function loginUser(email: string, password: string): Promise<String | null> {
|
||||
|
|
Loading…
Reference in New Issue
Block a user