From b2a971fd30cde4699a517590d64425448bcfc4a1 Mon Sep 17 00:00:00 2001 From: andres Date: Wed, 13 Mar 2024 16:11:10 +0100 Subject: [PATCH] fix order by cardscount --- src/modules/decks/infrastructure/decks.repository.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/decks/infrastructure/decks.repository.ts b/src/modules/decks/infrastructure/decks.repository.ts index f162167..d7eb6a8 100644 --- a/src/modules/decks/infrastructure/decks.repository.ts +++ b/src/modules/decks/infrastructure/decks.repository.ts @@ -96,7 +96,7 @@ export class DecksRepository { ['ASC', 'DESC'].includes(direction) ) { if (field === 'cardsCount') { - orderField = 'cardsCount' + orderField = '"cardsCount"' } else if (field === 'author.name') { orderField = 'a.name' } else {