From 7a1023786ef6deacd347cdd6736d0238b2f091d0 Mon Sep 17 00:00:00 2001 From: Stas Vilchik Date: Tue, 1 Nov 2016 17:53:07 +0100 Subject: [PATCH] fix loading more code --- .../sonar-web/src/main/js/components/source-viewer/main.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/server/sonar-web/src/main/js/components/source-viewer/main.js b/server/sonar-web/src/main/js/components/source-viewer/main.js index f1bdef0ea56..50d476d0f57 100644 --- a/server/sonar-web/src/main/js/components/source-viewer/main.js +++ b/server/sonar-web/src/main/js/components/source-viewer/main.js @@ -209,8 +209,8 @@ export default Marionette.LayoutView.extend({ // don't display global error 403: null } - }).done(function (data) { - let source = (data.sources || []).slice(0); + }).done(function (r) { + let source = (r.sources || []).slice(0); if (source.length === 0 || (source.length > 0 && _.first(source).line === 1)) { source.unshift({ line: 0 }); } @@ -225,7 +225,7 @@ export default Marionette.LayoutView.extend({ source, hasCoverage: that.model.hasCoverage(source), hasSourceBefore: firstLine > 1, - hasSourceAfter: data.sources.length === linesRequested + hasSourceAfter: r.sources.length === linesRequested }); that.model.checkIfHasDuplications(); }).fail(function (request) { -- 2.39.5