From b1857d5f8e515c11844408661bcbd50e20bed39d Mon Sep 17 00:00:00 2001 From: kload Date: Fri, 9 May 2014 21:54:45 +0000 Subject: [PATCH] [fix] Line break in package changelog --- js/app.js | 4 ++++ views/tools/tools_update.ms | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/js/app.js b/js/app.js index f3a0002e..a1528e27 100644 --- a/js/app.js +++ b/js/app.js @@ -952,6 +952,10 @@ app = Sammy('#main', function (sam) { // System update & upgrade sam.get('#/tools/update', function (c) { c.api('/update', function(data) { + packagesLength = data.packages.length; + for(var i = 0; i < packagesLength; i++) { + data.packages[i].changelog = data.packages[i].changelog.replace(/\n/g, '
'); + } c.view('tools/tools_update', data); }, 'PUT'); }); diff --git a/views/tools/tools_update.ms b/views/tools/tools_update.ms index 18c168d4..76199504 100644 --- a/views/tools/tools_update.ms +++ b/views/tools/tools_update.ms @@ -16,12 +16,12 @@ {{#packages}}

{{name}} {{fullname}}

-

{{changelog}}

+

{{{changelog}}}

{{/packages}}
- Upgrade packages + Upgrade packages {{else}} There is no packages to upgrade. {{/if}}