removes spaces in at start and end of product name on creation

closes #3007
This commit is contained in:
phyzical 2022-04-01 20:58:36 +08:00
parent a1871fb0e9
commit 1eca9449a0

@ -419,7 +419,7 @@ export function MakeProduct(
} }
const product = new Product({ const product = new Product({
name: productName.replace(/[<>]/g, ""), //Sanitize for HTMl elements name: productName.replace(/[<>]/g, "").trim(), //Sanitize for HTMl elements
createCity: city, createCity: city,
designCost: designInvest, designCost: designInvest,
advCost: marketingInvest, advCost: marketingInvest,