feat: set default language on instance (#3594)

This commit is contained in:
Livio Amstutz
2022-05-03 15:58:38 +02:00
committed by GitHub
parent 462fe10dab
commit 79db247801
12 changed files with 83 additions and 35 deletions

View File

@@ -98,9 +98,6 @@ func AddHumanCommand(a *user.Aggregate, human *AddHuman, passwordAlg crypto.Hash
return nil, errors.ThrowInvalidArgument(nil, "V2-zzad3", "Errors.Invalid.Argument")
}
if human.PreferredLanguage == language.Und {
return nil, errors.ThrowInvalidArgument(nil, "USER-Sfd11", "Errors.Invalid.Argument")
}
if human.FirstName = strings.TrimSpace(human.FirstName); human.FirstName == "" {
return nil, errors.ThrowInvalidArgument(nil, "USER-UCej2", "Errors.Invalid.Argument")
}