Skip to content

Commit 2a100fe

Browse files
authored
Update search.js
1 parent 2e09afc commit 2a100fe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/plugins/search/search.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ export function init(config, vm) {
211211
config.pathNamespaces.find(prefix => path && path.startsWith(prefix)) ||
212212
namespaceSuffix;
213213
} else if (config.pathNamespaces instanceof RegExp) {
214-
const matches = path.match(config.pathNamespaces);
214+
const matches = path && path.match(config.pathNamespaces);
215215

216216
if (matches) {
217217
namespaceSuffix = matches[0];

0 commit comments

Comments
 (0)