From d85896dcaa48112d7d23e12288f9f3d1dd6a35b8 Mon Sep 17 00:00:00 2001 From: Anthony Mineo Date: Sat, 29 Aug 2020 19:26:53 -0400 Subject: [PATCH] Better return error messages --- app/api/src/games/games.service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/api/src/games/games.service.ts b/app/api/src/games/games.service.ts index aae86f5..5b11809 100644 --- a/app/api/src/games/games.service.ts +++ b/app/api/src/games/games.service.ts @@ -36,7 +36,7 @@ export class GamesService { gameId: 'DESC' } }); - if (!game) { + if (!game.length) { throw new NotFoundException(`Game Type: ${gametype} not found`); } return game;