Shun Miyazawa 1 год назад
Родитель
Сommit
eb1974dd14

+ 2 - 0
apps/app/src/consts/user.ts

@@ -0,0 +1,2 @@
+
+export const DEFAULT_PASSOWRD_MINIMUM_NUMBER = 8;

+ 1 - 1
apps/app/src/server/middlewares/login-form-validator.ts

@@ -1,7 +1,7 @@
 import { ErrorV3 } from '@growi/core/dist/models';
 import { body, validationResult, type ValidationChain } from 'express-validator';
 
-const DEFAULT_PASSOWRD_MINIMUM_NUMBER = 8;
+import { DEFAULT_PASSOWRD_MINIMUM_NUMBER } from '~/consts/user';
 
 // form rules
 export const loginRules = (minPasswordLength?: number): ValidationChain[] => {

+ 1 - 1
apps/app/src/server/middlewares/register-form-validator.ts

@@ -1,7 +1,7 @@
 import { ErrorV3 } from '@growi/core/dist/models';
 import { body, validationResult, type ValidationChain } from 'express-validator';
 
-const DEFAULT_PASSOWRD_MINIMUM_NUMBER = 8;
+import { DEFAULT_PASSOWRD_MINIMUM_NUMBER } from '~/consts/user';
 
 // form rules
 export const registerRules = (minPasswordLength?: number): ValidationChain[] => {