changed the cross origin authentication
added CORS to enable cross-origin