diff options
Diffstat (limited to 'server.ts')
-rw-r--r-- | server.ts | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -48,6 +48,9 @@ if (errorMessage !== null) { | |||
48 | throw new Error(errorMessage) | 48 | throw new Error(errorMessage) |
49 | } | 49 | } |
50 | 50 | ||
51 | // Trust our proxy (IP forwarding...) | ||
52 | app.set('trust proxy', CONFIG.TRUST_PROXY) | ||
53 | |||
51 | // ----------- Database ----------- | 54 | // ----------- Database ----------- |
52 | 55 | ||
53 | // Initialize database and models | 56 | // Initialize database and models |
@@ -81,6 +84,7 @@ if (isTestInstance()) { | |||
81 | ) { | 84 | ) { |
82 | return (cors({ | 85 | return (cors({ |
83 | origin: 'http://localhost:3000', | 86 | origin: 'http://localhost:3000', |
87 | exposedHeaders: 'Retry-After', | ||
84 | credentials: true | 88 | credentials: true |
85 | }))(req, res, next) | 89 | }))(req, res, next) |
86 | } | 90 | } |