Added middleware to add CORS header