diff --git a/src/octoprint/static/js/app/viewmodels/loginstate.js b/src/octoprint/static/js/app/viewmodels/loginstate.js index c67273c2a..d00e7f804 100644 --- a/src/octoprint/static/js/app/viewmodels/loginstate.js +++ b/src/octoprint/static/js/app/viewmodels/loginstate.js @@ -20,6 +20,8 @@ $(function() { self.elementPasswordInput = undefined; self.elementLoginButton = undefined; + self.externalAddressNotification = undefined; + self.userMenuText = ko.pureComputed(function() { if (self.loggedIn()) { return self.username(); @@ -80,10 +82,15 @@ $(function() { "everyone with an internet connection.

Please see " + "this blog post for " + "ways to safely access your OctoPrint instance from remote.

" + - "

If you know what you are doing or you are sure this message is" + + "

If you know what you are doing or you are sure this message is " + "mistaken since you are in an isolated LAN, feel free to ignore it.

"); text = _.sprintf(text, {url: "https://octoprint.org/blog/2018/09/03/safe-remote-access/"}); - new PNotify({ + + if (self.externalAddressNotification !== undefined) { + self.externalAddressNotification.remove(); + } + + self.externalAddressNotification = new PNotify({ title: gettext("Possible external access detected"), text: text, hide: false,