mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-06 15:27:27 +00:00
misc: updated to use regex literal
This commit is contained in:
@@ -100,7 +100,7 @@ export const isFQDN = (str: string, options: FQDNOptions = {}): boolean => {
|
|||||||
const partRegex = new RE2(/^[a-z_\u00a1-\uffff0-9-]+$/i);
|
const partRegex = new RE2(/^[a-z_\u00a1-\uffff0-9-]+$/i);
|
||||||
const fullWidthRegex = new RE2(/[\uff01-\uff5e]/);
|
const fullWidthRegex = new RE2(/[\uff01-\uff5e]/);
|
||||||
const hyphenRegex = new RE2(/^-|-$/);
|
const hyphenRegex = new RE2(/^-|-$/);
|
||||||
const underscoreRegex = new RE2("_");
|
const underscoreRegex = new RE2(/_/);
|
||||||
|
|
||||||
return parts.every((part) => {
|
return parts.every((part) => {
|
||||||
if (part.length > 63 && !opts.ignore_max_length) {
|
if (part.length > 63 && !opts.ignore_max_length) {
|
||||||
|
|||||||
Reference in New Issue
Block a user