mirror of
https://github.com/zadam/trilium.git
synced 2026-01-08 00:12:12 +01:00
electron: Ignore TRILIUM_HOST env (fixes #368)
This commit is contained in:
@@ -1,3 +1,13 @@
|
||||
import config from "./config.js";
|
||||
import utils from "./utils.js";
|
||||
|
||||
export default process.env.TRILIUM_HOST || config['Network']['host'] || '0.0.0.0';
|
||||
function getHost() {
|
||||
const envHost = process.env.TRILIUM_HOST;
|
||||
if (envHost && !utils.isElectron) {
|
||||
return envHost;
|
||||
}
|
||||
|
||||
return config['Network']['host'] || '0.0.0.0';
|
||||
}
|
||||
|
||||
export default getHost();
|
||||
Reference in New Issue
Block a user