Make sure question mark is included in query string

Fixes #1672. This was edited in the GitHub GUI so bear with me :wink: