diff options
author | Christopher Speller <crspeller@gmail.com> | 2015-06-19 09:52:04 -0400 |
---|---|---|
committer | Christopher Speller <crspeller@gmail.com> | 2015-06-19 09:52:04 -0400 |
commit | 6e0a92a1a36e8819c471bae88af23d128691f8bc (patch) | |
tree | b4abab5968302a6ec1bc20a155287721be08209b | |
parent | e953475ddd538ce12bbe52107dedd66d26b0f108 (diff) | |
download | chat-6e0a92a1a36e8819c471bae88af23d128691f8bc.tar.gz chat-6e0a92a1a36e8819c471bae88af23d128691f8bc.tar.bz2 chat-6e0a92a1a36e8819c471bae88af23d128691f8bc.zip |
Defaulting to domain of localhost when no domain is given
-rw-r--r-- | utils/config.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/utils/config.go b/utils/config.go index 23bd3e85a..6a7e4589c 100644 --- a/utils/config.go +++ b/utils/config.go @@ -221,6 +221,10 @@ func LoadConfig(fileName string) { // Grabs the domain from enviroment variable if not in configuration if config.ServiceSettings.Domain == "" { config.ServiceSettings.Domain = os.Getenv("MATTERMOST_DOMAIN") + // If the enviroment variable is not set, use a default + if config.ServiceSettings.Domain == "" { + config.ServiceSettings.Domain = "localhost" + } } // Check for a valid email for feedback, if not then do feedback@domain |