Fix a bad check for valid URIs
Merge pull request #1117 from FredKSchott/fix-bad-uri-check

Fix a bad check for valid URIs