Commit ef09600b authored by Dev Jones's avatar Dev Jones
Browse files

no trailing slash on shopify prefixes

parent 23cb865c
// Copied from https://github.com/Shopify/shopify_app
const requestStorageAccess = (shop: string, prefix = '/') => {
const requestStorageAccess = (shop: string, prefix = '') => {
return `(function() {
function redirect() {
var targetInfo = {
myshopifyUrl: "https://${encodeURIComponent(shop)}",
hasStorageAccessUrl: "${prefix}auth/inline?shop=${encodeURIComponent(
hasStorageAccessUrl: "${prefix}/auth/inline?shop=${encodeURIComponent(
shop,
)}",
doesNotHaveStorageAccessUrl: "${prefix}auth/enable_cookies?shop=${encodeURIComponent(
doesNotHaveStorageAccessUrl: "${prefix}/auth/enable_cookies?shop=${encodeURIComponent(
shop,
)}",
appTargetUrl: "${prefix}?shop=${encodeURIComponent(shop)}"
appTargetUrl: "${prefix}/?shop=${encodeURIComponent(shop)}"
}
if (window.top == window.self) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment