master: Fixed the issues with OPTIONS requests to conform to the CORS spec.