Skip to content

Commit f494147

Browse files
committed
Update
1 parent 8dc35e8 commit f494147

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/plugins/search/search.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -236,10 +236,9 @@ export function init(config, vm) {
236236
namespaceSuffix = matches[0];
237237
}
238238
}
239-
if (
240-
paths.indexOf(namespaceSuffix + '/') === -1 &&
241-
paths.indexOf(namespaceSuffix + '/README') === -1
242-
) {
239+
const isExistHome = paths.indexOf(namespaceSuffix + '/') === -1;
240+
const isExistReadme = paths.indexOf(namespaceSuffix + '/README') === -1;
241+
if (isExistHome && isExistReadme) {
243242
paths.unshift(namespaceSuffix + '/');
244243
}
245244
} else if (paths.indexOf('/') === -1 && paths.indexOf('/README') === -1) {

0 commit comments

Comments
 (0)