From 07425148ee60ee8bcaf629cb118774060fa0c60b Mon Sep 17 00:00:00 2001 From: Norbert Renner Date: Wed, 5 Feb 2020 19:59:55 +0100 Subject: [PATCH] Set custom profileName after post Otherwise next cache get after tab switching still uses original profile --- js/control/Profile.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/js/control/Profile.js b/js/control/Profile.js index b955bd3..574e533 100644 --- a/js/control/Profile.js +++ b/js/control/Profile.js @@ -86,6 +86,7 @@ BR.Profile = L.Evented.extend({ callback: L.bind(function(err, profileId, profileText) { $(button).blur(); if (!err) { + this.profileName = profileId; this.cache[profileId] = profileText; if (!this.saveWarningShown) { @@ -127,6 +128,7 @@ BR.Profile = L.Evented.extend({ profileText: profileText, callback: function(err, profileId, profileText) { if (!err) { + that.profileName = profileId; that.cache[profileId] = profileText; } }