Fixed bug with the request object
Updated tests