Closed daeh closed 1 year ago
Thanks for this. It may be best to move all the url building away from strings and to urlparse and urlunparse. Accepting this fix, and tracking the future work in #8.
++ Makes total sense. I started off using urlparse but didn't want to do much refactoring without having a blueprint of the roadmap. So I just went with the simplest possible solution for this single case.
Amazing work on this. When I followed the setup instructions, the url I copied from my browser into .env came as
https://mastodon.online/
. The terminal slash in the MASTODON_BASE_URL variable led all of the urls returned byget_home_url()
to be invalid. This PR adds minimal string sanitation to strip terminal slashes from the mastodon_base_url variable.