FIX: should set headers for current request

Sometimes an error occurs about the headers global not existing,
I believe that the headers dict in question belongs to the request
object