fixed a bug in request method