Redirect requests in onBeforeRequest?

I am porting Requestly - Chrome Extension chrome store link to Firefox web extension. Basically, we can manipulate HTTP(s) requests like redirecting, blocking, manipulating headers etc.

Chrome allows to redirect a request in onBeforeRequest phase existing implementation but Mozilla Api does not allow redirection in onBeforeRequest phase but allows in onBeforeSendHeaders phase.

Check this out: “Redirection is not allowed in onBeforeRequest or onHeadersReceived, but is allowed in onBeforeSendHeaders.” available at API Docs

Why is there a difference between both the APIs ? Is there going to be a standard by w3c which should be followed by each browser. Otherwise, it would be difficult to handle such things within code.

This should be fixed in Firefox 47. It was only fixed a couple of weeks ago, so install a new build and try it.

Awesome… BTW Any word on

Is there going to be a standard by w3c which should be followed by each browser ?

Because every browser can try to move in different direction after certain point. So just wanted to know if some spec is followed or not ?