Better query string handling