projects
/
vchess.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove test instructions, fix CORS for DELETE method
[vchess.git]
/
server
/
app.js
diff --git
a/server/app.js
b/server/app.js
index
d4aef28
..
13cf1db
100644
(file)
--- a/
server/app.js
+++ b/
server/app.js
@@
-36,8
+36,9
@@
if (params.cors.enable)
app.use(function(req, res, next) {
res.header("Access-Control-Allow-Origin", params.cors.allowedOrigin);
res.header("Access-Control-Allow-Headers",
app.use(function(req, res, next) {
res.header("Access-Control-Allow-Origin", params.cors.allowedOrigin);
res.header("Access-Control-Allow-Headers",
- "Origin, X-Requested-With, Content-Type, Accept");
- next();
+ "Origin, X-Requested-With, Content-Type, Accept");
+ res.header("Access-Control-Allow-Methods", "GET, POST, OPTIONS, PUT, DELETE");
+ next();
});
}
});
}