mirror of
https://github.com/pierre42100/ComunicWeb
synced 2024-12-26 10:58:49 +00:00
22 lines
374 B
JavaScript
22 lines
374 B
JavaScript
/**
|
|
* Server configuration
|
|
*
|
|
* @author Pierre Hubert
|
|
*/
|
|
|
|
let _serverConfigCache = null;
|
|
|
|
class ServerConfig {
|
|
|
|
static async ensureLoaded() {
|
|
if (!_serverConfigCache)
|
|
_serverConfigCache = await api("server/config");
|
|
}
|
|
|
|
/**
|
|
* @returns {StaticServerConfig}
|
|
*/
|
|
static get conf() {
|
|
return _serverConfigCache;
|
|
}
|
|
} |