diff options
author | Sadie Powell <sadie@witchery.services> | 2020-12-20 03:04:21 +0000 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2020-12-20 03:05:29 +0000 |
commit | 6cfabb0064cab52bbbab59974e53dc0fa1954da7 (patch) | |
tree | aa755e92103730ba6428332b4094578cde91cc67 /include/configreader.h | |
parent | 029ff235e184acc8194e76ef535e437cb6c9f614 (diff) |
Hide the server name/desc better when <options:hideserver> is set.
Diffstat (limited to 'include/configreader.h')
-rw-r--r-- | include/configreader.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/configreader.h b/include/configreader.h index 7274dfad8..3a5ea9c60 100644 --- a/include/configreader.h +++ b/include/configreader.h @@ -451,6 +451,12 @@ class CoreExport ServerConfig */ const std::string& GetSID() const { return sid; } + /** Retrieves the server name which should be shown to users. */ + const std::string& GetServerName() const { return HideServer.empty() ? ServerName : HideServer; } + + /** Retrieves the server description which should be shown to users. */ + const std::string& GetServerDesc() const { return HideServer.empty() ? ServerDesc : HideServer; } + /** Read the entire configuration into memory * and initialize this class. All other methods * should be used only by the core. |