diff --git a/petstore/petstoreapp/soulmachines-react-app/src/components/ContentCards/ButtonWithImage.js b/petstore/petstoreapp/soulmachines-react-app/src/components/ContentCards/ButtonWithImage.js index ea982241..0bf50dc2 100644 --- a/petstore/petstoreapp/soulmachines-react-app/src/components/ContentCards/ButtonWithImage.js +++ b/petstore/petstoreapp/soulmachines-react-app/src/components/ContentCards/ButtonWithImage.js @@ -9,8 +9,8 @@ function ButtonWithImage({ data, className }) { const handleButtonClick = (e) => { e.preventDefault(); - const url = `${window.parent.location}`; - console.log(`${url} ${productId}`); + const url = window.parent.location.toString(); + console.log(`${url} ${productId}`); const session = url.split('sid=')[1].split('&')[0]; const csrf = url.split('csrf=')[1]; const azureURL = `https://azurepetstore.com/api/updatecart?csrf=${csrf}&productId=${productId}`;