Open HenriksApsitis opened 5 months ago
Thank you for pointing this out! In addition to that, possibly we overwrite other customised CORS settings unexpectedly. (We might have to keep other origins).
I will address it later! Thank you for your report!
Abstract
Cors origins check takes spaces into count.
Expected behaviour
Actually happened
Database configuration check does not remove spaces before if statement. Relevant code:
https://github.com/vrtmrz/obsidian-livesync/blob/93e7cbb133334d70cd2f48d38a6a2f7e933825c8/docs/setup_own_server.md?plain=1#L40
https://github.com/vrtmrz/obsidian-livesync/blob/93e7cbb133334d70cd2f48d38a6a2f7e933825c8/src/ObsidianLiveSyncSettingTab.ts#L418
https://github.com/vrtmrz/obsidian-livesync/blob/93e7cbb133334d70cd2f48d38a6a2f7e933825c8/src/ObsidianLiveSyncSettingTab.ts#L421
Fix
Add trim on split or update documentation. Possible solution is to add .map(item => item.trim()) to line https://github.com/vrtmrz/obsidian-livesync/blob/93e7cbb133334d70cd2f48d38a6a2f7e933825c8/src/ObsidianLiveSyncSettingTab.ts#L418
Reproducing procedure
Plugin version 0.22.1 Container version couchdb:3.3.3
Screenshots
Fixed: