diff options
author | Jeff Mitchell <etherpad@jefferai.org> | 2010-04-07 18:42:31 -0400 |
---|---|---|
committer | Jeff Mitchell <etherpad@jefferai.org> | 2010-04-07 18:42:31 -0400 |
commit | 25e821ece450b366990c7c353ec00261d9bbc5a5 (patch) | |
tree | e85429e55cb07a899d01fbe3a497b646cc1f9905 | |
parent | 6dbb148634b9cde9581708b652a49b195b58e484 (diff) | |
download | etherpad-25e821ece450b366990c7c353ec00261d9bbc5a5.tar.gz etherpad-25e821ece450b366990c7c353ec00261d9bbc5a5.tar.xz etherpad-25e821ece450b366990c7c353ec00261d9bbc5a5.zip |
If hidePorts is enabled, don't show port numbers in e.g. emails. Useful when you're running behind a proxy but EP doesn't know it, so that it doesn't tack on :9000 in links in emails.
-rw-r--r-- | etherpad/src/etherpad/utils.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/etherpad/src/etherpad/utils.js b/etherpad/src/etherpad/utils.js index 398090c..3e35f00 100644 --- a/etherpad/src/etherpad/utils.js +++ b/etherpad/src/etherpad/utils.js @@ -388,7 +388,7 @@ function isStaticRequest() { function httpsHost(h) { h = h.split(":")[0]; // strip any existing port - if (appjet.config.listenSecurePort != "443") { + if (appjet.config.listenSecurePort != "443" && !appjet.config.hidePorts) { h = (h + ":" + appjet.config.listenSecurePort); } return h; @@ -396,7 +396,7 @@ function httpsHost(h) { function httpHost(h) { h = h.split(":")[0]; // strip any existing port - if (appjet.config.listenPort != "80") { + if (appjet.config.listenPort != "80" && !appjet.config.hidePorts) { h = (h + ":" + appjet.config.listenPort); } return h; |