changed responses of createOrder controller

master
parent 50f6e48219
commit 8d2d2d29e3

@ -243,10 +243,10 @@ exports.createOrder = async (req, res, next) => {
res.status(201).json({ message: 'Order created successfully', newOrder });
res.status(201).json(true);
} catch (error) {
console.error(error);
res.status(500).json({ message: 'Error creating order' });
res.status(500).json(false);
}
};

Loading…
Cancel
Save