From 18cbc446563b4775914b88235159e2fdfaf527f3 Mon Sep 17 00:00:00 2001 From: Sam Wing Date: Mon, 18 Nov 2019 20:38:53 -0500 Subject: [PATCH] no item.name if not productData --- routes/wishlist/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/routes/wishlist/index.js b/routes/wishlist/index.js index 5f73b95..ff0bffc 100644 --- a/routes/wishlist/index.js +++ b/routes/wishlist/index.js @@ -79,7 +79,7 @@ module.exports = (db) => { } catch (err) { req.flash('error', err.toString()); } - item.name = (productData ? productData.name : req.body.itemUrlOrName); + item.name = (productData ? productData.name : ''); item.addedBy = req.user._id; item.pledgedBy = (req.user._id === req.params.user ? undefined : req.user._id); item.note = req.body.note;