@@ -45,7 +45,7 @@ export class RunnerSelfServiceController {
 | 
			
		||||
		let runner = await createRunner.toEntity();
 | 
			
		||||
 | 
			
		||||
		runner = await this.runnerRepository.save(runner);
 | 
			
		||||
		let response = new ResponseSelfServiceRunner(await this.runnerRepository.findOne(runner, { relations: ['scans', 'group', 'scans.track', 'cards', 'distanceDonations', 'distanceDonations.donor', 'distanceDonations.runner', 'distanceDonations.runner.scans', 'distanceDonations.runner.scans.track'] }));
 | 
			
		||||
		let response = new ResponseSelfServiceRunner(await this.runnerRepository.findOne(runner, { relations: ['scans', 'group', 'group.parentGroup', 'scans.track', 'cards', 'distanceDonations', 'distanceDonations.donor', 'distanceDonations.runner', 'distanceDonations.runner.scans', 'distanceDonations.runner.scans.track'] }));
 | 
			
		||||
		response.token = JwtCreator.createSelfService(runner);
 | 
			
		||||
		return response;
 | 
			
		||||
	}
 | 
			
		||||
@@ -60,7 +60,7 @@ export class RunnerSelfServiceController {
 | 
			
		||||
		let runner = await createRunner.toEntity(org);
 | 
			
		||||
		runner = await this.runnerRepository.save(runner);
 | 
			
		||||
 | 
			
		||||
		let response = new ResponseSelfServiceRunner(await this.runnerRepository.findOne(runner, { relations: ['scans', 'group', 'scans.track', 'cards', 'distanceDonations', 'distanceDonations.donor', 'distanceDonations.runner', 'distanceDonations.runner.scans', 'distanceDonations.runner.scans.track'] }));
 | 
			
		||||
		let response = new ResponseSelfServiceRunner(await this.runnerRepository.findOne(runner, { relations: ['scans', 'group', 'group.parentGroup', 'scans.track', 'cards', 'distanceDonations', 'distanceDonations.donor', 'distanceDonations.runner', 'distanceDonations.runner.scans', 'distanceDonations.runner.scans.track'] }));
 | 
			
		||||
		response.token = JwtCreator.createSelfService(runner);
 | 
			
		||||
		return response;
 | 
			
		||||
	}
 | 
			
		||||
@@ -78,7 +78,7 @@ export class RunnerSelfServiceController {
 | 
			
		||||
			throw new InvalidCredentialsError();
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		const runner = await this.runnerRepository.findOne({ id: jwtPayload["id"] }, { relations: ['scans', 'group', 'scans.track', 'cards', 'distanceDonations', 'distanceDonations.donor', 'distanceDonations.runner', 'distanceDonations.runner.scans', 'distanceDonations.runner.scans.track'] });
 | 
			
		||||
		const runner = await this.runnerRepository.findOne({ id: jwtPayload["id"] }, { relations: ['scans', 'group', 'group.parentGroup', 'scans.track', 'cards', 'distanceDonations', 'distanceDonations.donor', 'distanceDonations.runner', 'distanceDonations.runner.scans', 'distanceDonations.runner.scans.track'] });
 | 
			
		||||
		if (!runner) { throw new RunnerNotFoundError() }
 | 
			
		||||
		return runner;
 | 
			
		||||
	}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user