patch frontend api endpoint in config

This commit is contained in:
Sorrel Bri 2020-01-18 01:33:24 -08:00 committed by sorrelbri
parent b69edb9182
commit 68fedb4d2f
2 changed files with 1 additions and 6 deletions

View file

@ -4,7 +4,7 @@ const env = runtimeEnv();
const production = { const production = {
apiAddress: 'https://node-go-api.herokuapp.com/api/v1', apiAddress: 'https://node-go-api.herokuapp.com/api/v1',
endpoint: 'https://play-node-go.herokuapp.com', endpoint: 'https://play-node-go.herokuapp.com',
authAddress: 'https://node-go.herokuapp.com/auth', authAddress: 'https://node-go-api.herokuapp.com/auth',
socketAddress: 'https://node-go-api.herokuapp.com' socketAddress: 'https://node-go-api.herokuapp.com'
} }

View file

@ -28,11 +28,6 @@ const corsOptions = {
app.options('*', cors(corsOptions)); app.options('*', cors(corsOptions));
app.use('*', cors(corsOptions)); app.use('*', cors(corsOptions));
app.use((req, res, next) => {
res.header("Access-Control-Allow-Origin", allowedOrigin);
res.header("Access-Control-Allow-Headers", "Origin, X-Requested-With, Content-Type, Accept");
next();
});
// disable logging for tests // disable logging for tests
if (process.env.NODE_ENV !== 'test') app.use(logger('dev')); if (process.env.NODE_ENV !== 'test') app.use(logger('dev'));