Skip to content

Commit

Permalink
fix bug in code
Browse files Browse the repository at this point in the history
  • Loading branch information
marusoft committed Jul 16, 2019
1 parent cb0e8d2 commit ca9c308
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
1 change: 0 additions & 1 deletion server/controllers/carControllers.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ console.log("My body",req.body)
message: 'Car Advert Successfully created',
});
} catch (error) {
console.log("Car error",error.message);
return res.status(500).json({
status: 500,
error: error.message,
Expand Down
3 changes: 2 additions & 1 deletion server/controllers/orderControllers.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@ class Orders {
*/
static async CreateAPurchaseOrder(req, res) {
const userid = req.user.id;
console.log('val', req.body);
const { car_id } = req.body;
const value = Number(car_id);
console.log('val', value);

const carSql = 'SELECT * FROM cars WHERE id = $1';

try {
Expand Down

0 comments on commit ca9c308

Please sign in to comment.