Throws more verbose exception if invalid query parameter is provided