Update request.rb: add some methods