From 2189072f8544d77be03499aa1ff346d387a8ecae Mon Sep 17 00:00:00 2001 From: cat Date: Wed, 8 Jan 2014 09:59:45 +0100 Subject: [PATCH] LSP: bugfix - limit moving was broken in the minimized version --- lsp/footer.html | 25 ++++++++++++++++++++++++- lsp/pages.js | 21 +-------------------- lsp/server.html | 25 ++++++++++++++++++++++++- 3 files changed, 49 insertions(+), 22 deletions(-) diff --git a/lsp/footer.html b/lsp/footer.html index f0fcea34..b9209e1e 100644 --- a/lsp/footer.html +++ b/lsp/footer.html @@ -1,5 +1,6 @@ diff --git a/lsp/pages.js b/lsp/pages.js index 9519e01d..4c319ada 100755 --- a/lsp/pages.js +++ b/lsp/pages.js @@ -787,26 +787,7 @@ function showTab(tabName,streamName) { } if (applyInput() === false) { return; } - var destination = $('#limit-applies-to').val(); - if ((streamName == '_new_') || (destination != streamName[0])) { - var target; - if (destination == 'server') { - if (!settings.settings.config.limits) { - settings.settings.config.limits = []; - } - target = settings.settings.config.limits; - } - else { - destination = destination.replace('stream-',''); - if (!settings.settings.streams[destination].limits) { - settings.settings.streams[destination].limits = []; - } - target = settings.settings.streams[destination].limits; - } - - eval('target.push(settings.'+objpath+');'); - eval('delete settings.'+objpath+';'); - } + moveLimit($('#limit-applies-to').val(),streamName,objpath); saveAndReload('limits'); }) diff --git a/lsp/server.html b/lsp/server.html index 8336d485..ea792182 100755 --- a/lsp/server.html +++ b/lsp/server.html @@ -11,7 +11,8 @@