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

IsValidShopDomainAsync should check if shopDomain is a valid uri before building the shop domain uri #1067

Open
waheedbhatti opened this issue May 14, 2024 · 2 comments
Labels

Comments

@waheedbhatti
Copy link

Since the method IsValidShopDomainAsync is to determine whether the shopDomain variable is a valid shop domain it should also check if the shopDomain string is a valid uri before trying to build the shop domain uri.

For scenarios where the shop domain may have been entered by a user it is possible that it will not be a valid uri which will then throw an exception when passed to BuildShopDomainUri

@nozzlegear nozzlegear added the bug label May 14, 2024
@nozzlegear
Copy link
Owner

Hey, good catch! It used to do this, it looks like we lost this functionality when I rewrote the authorization service and split it into the ShopifyDomainUtility. It's using a UriBuilder to build the request url now, which must not do much validation. I'll add this validation back to the utility!

@waheedbhatti
Copy link
Author

Thank you for all your great work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants