From 2472861c8a0f319312bd1ea1686580c5ca870277 Mon Sep 17 00:00:00 2001 From: Jan Cizmar Date: Tue, 26 Dec 2023 08:22:55 +0100 Subject: [PATCH] fix: Organization validation constraints too strict (#2043) --- backend/data/src/main/kotlin/io/tolgee/model/Organization.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/data/src/main/kotlin/io/tolgee/model/Organization.kt b/backend/data/src/main/kotlin/io/tolgee/model/Organization.kt index d4b1707a70..fcccda0b39 100644 --- a/backend/data/src/main/kotlin/io/tolgee/model/Organization.kt +++ b/backend/data/src/main/kotlin/io/tolgee/model/Organization.kt @@ -28,13 +28,13 @@ class Organization( @Id @GeneratedValue(strategy = GenerationType.IDENTITY) override var id: Long = 0, - @field:NotBlank @field:Size(min = 3, max = 50) + @field:NotBlank @field:Size(min = 1, max = 50) open var name: String = "", open var description: String? = null, @Column(name = "address_part") - @field:NotBlank @field:Size(min = 3, max = 60) + @field:NotBlank @field:Size(min = 1, max = 60) @field:Pattern(regexp = "^[a-z0-9-]*[a-z]+[a-z0-9-_]*$", message = "invalid_pattern") open var slug: String = "",