allow emails without a tld (#2762)

It's perfectly valid to have an email address without a TLD, for instance:

- test@localhost
- test@svc-in-same-k8s-namespace
- test@internal-corp

Fixes #2667
This commit is contained in:
Thomas
2023-06-14 22:26:17 +01:00
committed by GitHub
parent eed1243263
commit 408fa45c51
8 changed files with 94 additions and 7 deletions
@@ -5,7 +5,7 @@ import { toEmail, toSanitized } from '@app/immich/utils/transform.util';
export class UpdateUserDto {
@IsOptional()
@IsEmail()
@IsEmail({ require_tld: false })
@Transform(toEmail)
email?: string;