From 166d16ce82b1cae52eb45e8e049b805c1c8c9aca Mon Sep 17 00:00:00 2001 From: Oliver Middleton Date: Sun, 6 May 2018 15:36:57 +0100 Subject: [PATCH] rustdoc: Fix missing search results This code seemed to be trying to remove duplicates from the search results but that should already have happened by this point. It was removing results that only differed in their parent causing missing results. --- src/librustdoc/html/static/main.js | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/src/librustdoc/html/static/main.js b/src/librustdoc/html/static/main.js index 6d80145b29c7c..99068a8479403 100644 --- a/src/librustdoc/html/static/main.js +++ b/src/librustdoc/html/static/main.js @@ -1236,20 +1236,10 @@ var output = ''; if (array.length > 0) { output = ''; - var shown = []; array.forEach(function(item) { - var name, type, href, displayPath; - - var id_ty = item.ty + item.path + item.name; - if (shown.indexOf(id_ty) !== -1) { - return; - } - - shown.push(id_ty); - name = item.name; - type = itemTypes[item.ty]; - + var name = item.name; + var type = itemTypes[item.ty]; var res = buildHrefAndPath(item); var href = res[1]; var displayPath = res[0];