Moved custom salugs regex to constant

This commit is contained in:
Alejandro Celaya
2020-08-09 10:24:59 +02:00
parent a66dca4f07
commit 87e8ae7af6
2 changed files with 4 additions and 2 deletions

View File

@@ -17,6 +17,7 @@ const MIN_SHORT_CODES_LENGTH = 4;
const DEFAULT_REDIRECT_STATUS_CODE = StatusCodeInterface::STATUS_FOUND;
const DEFAULT_REDIRECT_CACHE_LIFETIME = 30;
const LOCAL_LOCK_FACTORY = 'Shlinkio\Shlink\LocalLockFactory';
const CUSTOM_SLUGS_REGEXP = '/[^A-Za-z0-9._~]+/';
function generateRandomShortCode(int $length): string
{