From d3c19e0db9be6c4bfe481fbf649f0d10691bea79 Mon Sep 17 00:00:00 2001 From: rolux Date: Thu, 12 Feb 2015 18:12:10 +0100 Subject: [PATCH] remedy for strange bitrot in api dialog --- static/js/apiDialog.js | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/static/js/apiDialog.js b/static/js/apiDialog.js index ae55c6d7b..1d25436aa 100644 --- a/static/js/apiDialog.js +++ b/static/js/apiDialog.js @@ -157,20 +157,18 @@ pandora.ui.apiDialog = function() { ); parts = $doc.html().split('see' + colon + whitespace); if (parts.length == 2) { - parts[1] = parts[1] - .split(comma + linebreak) - .map(function(part) { - return part - .split(comma + whitespace) - .map(function(action) { - action = Ox.stripTags(action); - return '' + action + ''; - }) - .join(comma + whitespace); - + parts_ = parts[1].split('source' + colon + whitespace); + parts_[0] = parts_[0] + .split(comma + whitespace) + .map(function(action) { + action = Ox.stripTags(action); + return '' + action + ''; }) - .join(comma + linebreak); + .join(comma + whitespace); + parts[1] = parts_.join( + linebreak + linebreak + 'source' + colon + whitespace + ); $doc.html(parts.join('see' + colon + whitespace)); } pandora.createLinks($doc);