Crash when creating an Url object with Query String containing only the key part

If the query string does not contain a value pair (eg, `key=value`, but only `key`), the code crashes. This commit fixes that.