From 91258611aa5b152a7eedbd39cf7b1b40d6616bf2 Mon Sep 17 00:00:00 2001 From: Logfro Date: Mon, 16 Oct 2017 11:54:49 +0200 Subject: [PATCH] Added EU Support Added a second replace to also replace Euro when its a the european shop --- index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 48c6f9e..7d22b5b 100644 --- a/index.js +++ b/index.js @@ -108,7 +108,7 @@ api.getItems = function(category, callback) { link: link, description: $('.description').text(), addCartURL: addCartURL, - price: parseInt(($('.price')[0].children[0].children[0].data).replace('$', '').replace(',', '')), + price: parseInt(($('.price')[0].children[0].children[0].data).replace('$', '').replace('€','').replace(',', '')), image: image, sizesAvailable: sizesAvailable, images: [], @@ -194,7 +194,7 @@ api.getItem = function(itemURL, callback) { link: itemURL, description: $('.description').text(), addCartURL: addCartURL, - price: parseInt(($('.price')[0].children[0].children[0].data).replace('$', '').replace(',', '')), + price: parseInt(($('.price')[0].children[0].children[0].data).replace('$', '').replace('€','').replace(',', '')), image: 'http:' + $('#img-main').attr('src'), sizesAvailable: sizesAvailable, images: [],