|
@@ -31,10 +31,9 @@ app.use(bodyParser.urlencoded({ extended: true }));
|
31
|
31
|
app.use(bodyParser.json());
|
32
|
32
|
|
33
|
33
|
|
34
|
|
-// Allow cross-origin requests. Wildcard for now, we'll see if we can improve
|
35
|
|
-// that.
|
|
34
|
+// Allow cross-origin requests.
|
36
|
35
|
app.all('/*', function(req, res, next) {
|
37
|
|
- res.header('Access-Control-Allow-Origin', '*');
|
|
36
|
+ res.header('Access-Control-Allow-Origin', settings.formUrl);
|
38
|
37
|
res.header('Access-Control-Allow-Headers', 'Content-Type')
|
39
|
38
|
next();
|
40
|
39
|
});
|