Small request handler improvement

I've cutted the code.