parent
c01233b4d6
commit
e5dab3469c
|
@ -56,11 +56,14 @@ export class RunnerSelfServiceController {
|
|||
return responseScans;
|
||||
}
|
||||
|
||||
@Post('/runners/me/forgot')
|
||||
@Post('/runners/forgot')
|
||||
@ResponseSchema(RunnerNotFoundError, { statusCode: 404 })
|
||||
@OnUndefined(ResponseEmpty)
|
||||
@OpenAPI({ description: 'TODO' })
|
||||
async requestNewToken(@QueryParam('mail') mail: string) {
|
||||
if (!mail) {
|
||||
throw new RunnerNotFoundError();
|
||||
}
|
||||
const runner = await this.runnerRepository.findOne({ email: mail });
|
||||
if (!runner) { throw new RunnerNotFoundError(); }
|
||||
|
||||
|
|
Loading…
Reference in New Issue