|
|
@@ -1,7 +1,7 @@
|
|
|
import { GroupType } from '@growi/core';
|
|
|
// import { isGlobPatternPath, isCreatablePage } from '@growi/core/dist/utils/page-path-utils';
|
|
|
import { type ValidationChain, body } from 'express-validator';
|
|
|
-import { isCreatablePageWithGlob } from '../../../utils/is-creatable-page-with-glob'
|
|
|
+import { isCreatablePagePathPattern } from '../../../utils/is-creatable-page-path-pattern'
|
|
|
|
|
|
import { AiAssistantShareScope, AiAssistantAccessScope } from '../../../interfaces/ai-assistant';
|
|
|
|
|
|
@@ -43,7 +43,7 @@ export const upsertAiAssistantValidator: ValidationChain[] = [
|
|
|
.notEmpty()
|
|
|
.withMessage('pagePathPatterns must not be empty')
|
|
|
.custom((value: string) => {
|
|
|
- return isCreatablePageWithGlob(value);
|
|
|
+ return isCreatablePagePathPattern(value);
|
|
|
}),
|
|
|
|
|
|
body('grantedGroupsForShareScope')
|