From bfbc7ac7338abda5703fa1fcab9b8a06bf020cc1 Mon Sep 17 00:00:00 2001 From: Pascal Mugnier Date: Wed, 7 Mar 2018 12:05:05 +0100 Subject: [PATCH] SONAR-10397 Fix inconsistent list of files in "Code" tab with +100 files --- server/sonar-web/src/main/js/apps/code/bucket.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/server/sonar-web/src/main/js/apps/code/bucket.ts b/server/sonar-web/src/main/js/apps/code/bucket.ts index 8fc8bce8e65..503b56e30e8 100644 --- a/server/sonar-web/src/main/js/apps/code/bucket.ts +++ b/server/sonar-web/src/main/js/apps/code/bucket.ts @@ -17,6 +17,7 @@ * along with this program; if not, write to the Free Software Foundation, * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +import { concat } from 'lodash'; import { Breadcrumb, Component } from './types'; let bucket: { [key: string]: Component } = {}; @@ -43,6 +44,10 @@ export function addComponentChildren( total: number, page: number ): void { + const previous = getComponentChildren(componentKey); + if (previous) { + children = concat(children, previous.children); + } childrenBucket[componentKey] = { children, total, page }; } -- 2.39.5