From 0afa28de0953ed528486a7d7ad6000f344624710 Mon Sep 17 00:00:00 2001
From: Harrison Healey <harrisonmhealey@gmail.com>
Date: Tue, 9 Aug 2016 09:53:22 -0400
Subject: Changed autodetection of SiteURL (#3764)

* Changed autoconfiguration of SiteURL to be done on every request

* Added SiteURL to system console
---
 webapp/utils/utils.jsx | 4 ++++
 1 file changed, 4 insertions(+)

(limited to 'webapp/utils/utils.jsx')

diff --git a/webapp/utils/utils.jsx b/webapp/utils/utils.jsx
index e3db6d827..9731d3ce2 100644
--- a/webapp/utils/utils.jsx
+++ b/webapp/utils/utils.jsx
@@ -1338,3 +1338,7 @@ export function isValidPassword(password) {
 
     return errorMsg;
 }
+
+export function getSiteURL() {
+    return global.mm_config.SiteURL || window.location.origin;
+}
\ No newline at end of file
-- 
cgit v1.2.3-1-g7c22

