@@ -1212,7 +1212,7 @@ class DocSearch {
12121212 * will never fulfill.
12131213 */
12141214 async buildIndex ( ) {
1215- const nn = this . database . getIndex ( "normalizedName" ) ;
1215+ const nn = this . database . getData ( "normalizedName" ) ;
12161216 if ( ! nn ) {
12171217 return ;
12181218 }
@@ -3722,7 +3722,7 @@ class DocSearch {
37223722 * @returns {AsyncGenerator<rustdoc.ResultObject> }
37233723 */
37243724 async function * ( currentCrate ) {
3725- const index = this . database . getIndex ( "normalizedName" ) ;
3725+ const index = this . database . getData ( "normalizedName" ) ;
37263726 if ( ! index ) {
37273727 return ;
37283728 }
@@ -3851,8 +3851,7 @@ class DocSearch {
38513851 } ;
38523852 if ( elem . normalizedPathLast === "" ) {
38533853 // faster full-table scan for this specific case.
3854- const nameData = this . database . getData ( "name" ) ;
3855- const l = nameData ? nameData . length : 0 ;
3854+ const l = index . length ;
38563855 for ( let id = 0 ; id < l ; ++ id ) {
38573856 if ( ! idDuplicates . has ( id ) ) {
38583857 idDuplicates . add ( id ) ;
@@ -3954,7 +3953,7 @@ class DocSearch {
39543953 * @returns {AsyncGenerator<rustdoc.ResultObject> }
39553954 */
39563955 async function * ( inputs , output , typeInfo , currentCrate ) {
3957- const index = this . database . getIndex ( "normalizedName" ) ;
3956+ const index = this . database . getData ( "normalizedName" ) ;
39583957 if ( ! index ) {
39593958 return ;
39603959 }
0 commit comments