fix bug in /metrics?query fetches