Stop &explain=true from corrupting all future queries.

This was using global variables and was broken since the conversion
to Flask.  Move this data to the flask.request object so it doesn't
affect other requests.