@stati/core 1.23.1 → 1.23.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/search/generator.js +2 -2
- package/package.json +1 -1
package/dist/search/generator.js
CHANGED
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import { createHash } from 'node:crypto';
|
|
6
6
|
import { join } from 'node:path';
|
|
7
|
-
import { minimatch } from 'minimatch';
|
|
8
7
|
import { writeFile, ensureDir } from '../core/utils/fs.utils.js';
|
|
8
|
+
import { matchesGlob } from '../core/utils/glob-patterns.utils.js';
|
|
9
9
|
import { SEARCH_INDEX_VERSION, SEARCH_DEFAULTS } from './constants.js';
|
|
10
10
|
/**
|
|
11
11
|
* Generates a short content hash for cache busting.
|
|
@@ -191,7 +191,7 @@ export function shouldExcludePage(page, config) {
|
|
|
191
191
|
// Check exclude patterns
|
|
192
192
|
const excludePatterns = config.exclude ?? SEARCH_DEFAULTS.exclude;
|
|
193
193
|
for (const pattern of excludePatterns) {
|
|
194
|
-
if (
|
|
194
|
+
if (matchesGlob(page.url, pattern)) {
|
|
195
195
|
return true;
|
|
196
196
|
}
|
|
197
197
|
}
|