Fix singleton check in mysql

This commit is contained in:
rijkvanzanten
2020-08-13 14:09:57 -04:00
parent 12fc171dcf
commit 3912fac3a6

View File

@@ -24,7 +24,7 @@ const collectionExists: RequestHandler = asyncHandler(async (req, res, next) =>
.where({ collection: req.collection })
.first();
req.singleton = collectionInfo?.singleton || false;
req.singleton = collectionInfo?.singleton === true || collectionInfo?.singleton === 1;
return next();
});