Correction booléen asynchrone
This commit is contained in:
@ -49,7 +49,7 @@ export class GeolocationsService {
|
||||
}
|
||||
|
||||
async remove(id: number): Promise<Geolocation> {
|
||||
if (!this.findOne(id))
|
||||
if (!await this.findOne(id))
|
||||
throw new NotFoundException(`Aucune géolocalisation n'existe avec l'identifiant ${id}`)
|
||||
return await this.prisma.geolocation.delete({ where: { id } })
|
||||
}
|
||||
|
Reference in New Issue
Block a user