Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix and Refactor splash page URL Handling to Respect Nested URLs #1794

Merged
merged 2 commits into from
Feb 21, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,17 @@ def splash_page
embedded: params[:embedded],
)
end

def splash_page_with_params(params)
uri = URI(root_path)
uri = URI(base_url)
uri.query = params.compact.to_query
uri.to_s
end

def base_url
ShopifyApp.configuration.root_url.presence || root_path
end

def redirect_to_splash_page
redirect_to(splash_page)
rescue ::ShopifyApp::ShopifyDomainNotFound => error
Expand Down
Loading