Avoid to calculate the size of querystring for each request

Check non-emptiness using the first string char instead of calculating
the size