From 23638280920cafccd150400a425be5a8308e69c4 Mon Sep 17 00:00:00 2001 From: alexandre Date: Thu, 9 Mar 2023 08:54:03 +0100 Subject: [PATCH] hotfix clientUnpaid --- modules/client/back/methods/client/getCard.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/client/back/methods/client/getCard.js b/modules/client/back/methods/client/getCard.js index 99c59f757..a2365ee25 100644 --- a/modules/client/back/methods/client/getCard.js +++ b/modules/client/back/methods/client/getCard.js @@ -80,7 +80,7 @@ module.exports = function(Self) { const data = await Self.rawSql(query, [id, date], myOptions); client.debt = data[0].debt; - client.unpaid = await Self.app.models.ClientUnpaid.findOne({id}, myOptions); + client.unpaid = await Self.app.models.ClientUnpaid.findById(id, null, myOptions); return client; };