Eliminación de método
Eliminación del método de prueba del inició sesión
This commit is contained in:
parent
610f1fbfeb
commit
855d25dcd8
|
@ -44,6 +44,6 @@ export class UsersController {
|
||||||
findLogin(@Payload() body:string) {
|
findLogin(@Payload() body:string) {
|
||||||
let pemail= body['email'];
|
let pemail= body['email'];
|
||||||
let ppassword= body['password'];
|
let ppassword= body['password'];
|
||||||
return this.userService.findHero(pemail,ppassword);
|
return this.userService.findLogin(pemail,ppassword);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,10 +41,6 @@ export class UsersService {
|
||||||
|
|
||||||
//inicio de sesion
|
//inicio de sesion
|
||||||
async findLogin(email: string, password: string) : Promise<User> {
|
async findLogin(email: string, password: string) : Promise<User> {
|
||||||
return this.userModel.findOne({ email:email},{ password:password}).exec();
|
|
||||||
}
|
|
||||||
|
|
||||||
async findHero(email: string, password: string) : Promise<User> {
|
|
||||||
let repo1=this.userModel;
|
let repo1=this.userModel;
|
||||||
let userReturn = new Promise<User>((resolve, reject) => {
|
let userReturn = new Promise<User>((resolve, reject) => {
|
||||||
let repo =repo1;
|
let repo =repo1;
|
||||||
|
|
Loading…
Reference in New Issue