mirror of
https://github.com/pterodactyl/panel.git
synced 2026-12-01 03:45:53 -05:00
12 lines
281 B
TypeScript
12 lines
281 B
TypeScript
export const validateShortCode = (value: string): string | undefined => {
|
|
if (value.length < 1) {
|
|
return 'A short code must be provided.';
|
|
}
|
|
|
|
if (value.length > 60) {
|
|
return 'A short code must not exceed 60 characters.';
|
|
}
|
|
|
|
return undefined;
|
|
};
|