From dc15fa3ea1d89d9b78edfda796151c57ce7c688a Mon Sep 17 00:00:00 2001 From: Timur Shemsedinov Date: Sun, 20 Mar 2022 23:29:36 +0200 Subject: [PATCH] Make server config `cors.orogin` optional Refs: https://github.com/metarhia/impress/issues/1687 PR-URL: https://github.com/metarhia/impress/pull/1726 --- CHANGELOG.md | 1 + schemas/config/server.js | 2 +- types/config.d.ts | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 95ad52d9..a69c4980 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ ## [Unreleased][unreleased] - Improve error handling in master thread +- Server config `cors.origin` is now optional ## [2.6.8][] - 2022-03-19 diff --git a/schemas/config/server.js b/schemas/config/server.js index 01411c14..e079e140 100644 --- a/schemas/config/server.js +++ b/schemas/config/server.js @@ -27,6 +27,6 @@ timeout: 'number', }, cors: { - origin: 'string', + origin: '?string', }, }); diff --git a/types/config.d.ts b/types/config.d.ts index a32f9e55..7220e119 100644 --- a/types/config.d.ts +++ b/types/config.d.ts @@ -42,7 +42,7 @@ export interface ServerConfig { wait: number; timeout: number; }; - cors: { + cors?: { origin: string; }; }