1
0
Fork 0
mirror of https://github.com/pawelmalak/flame.git synced 2025-07-23 13:29:35 +02:00

Added option to change date formatting. Added shortcuts to clear search bar

This commit is contained in:
Paweł Malak 2021-10-22 15:51:11 +02:00
parent cfb471e578
commit 4ef9652ede
11 changed files with 68 additions and 13 deletions

View file

@ -15,14 +15,12 @@ exports.createCategory = asyncWrapper(async (req, res, next) => {
let category;
if (pinCategories) {
if (parseInt(pinCategories.value)) {
category = await Category.create({
...req.body,
isPinned: true,
});
} else {
category = await Category.create(req.body);
}
category = await Category.create({
...req.body,
isPinned: true,
});
} else {
category = await Category.create(req.body);
}
res.status(201).json({