fix condition

This commit is contained in:
hippoz 2023-02-05 23:33:50 +02:00
parent b3c7ffccc8
commit 8ba70833f3
Signed by: hippoz
GPG key ID: 56C4E02A85F2FBED

View file

@ -200,7 +200,7 @@ router.get(
const { before, count } = req.query;
let limit = typeof count === "string" ? parseInt(count || "25") : 25;
if (limit === NaN) {
if (Number.isNaN(limit)) {
return res.status(400).json({ ...errors.INVALID_DATA });
}