Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto-remove trailing slash and other unwanted errors from Nightscout URL
When users enter a trailing / in their Nightscout URL (Eg: "https://url/" rather than "https://url"), this will immediately result in a "Not found!" (404) error, because a / is already being appended. (Resulting in "https://url//"). This check removes the trailing slash, capital characters, symbols, etc. when the user enters it in to the URL field, to prevent 404's. Commit inspired by both my own as well as @bjorkert's commit to LoopFollow. Might not be the cleanest way, but it works.
- Loading branch information