From af8d0bca81ccddeeda8a544ec40fc88dbe33fe57 Mon Sep 17 00:00:00 2001 From: NathanFallet Date: Fri, 8 Dec 2023 18:42:28 +0100 Subject: [PATCH] Oups --- .../me/nathanfallet/extopy/models/auth/RegisterCodePayload.kt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/extopy-commons/src/commonMain/kotlin/me/nathanfallet/extopy/models/auth/RegisterCodePayload.kt b/extopy-commons/src/commonMain/kotlin/me/nathanfallet/extopy/models/auth/RegisterCodePayload.kt index 1aa7f7c..7630269 100644 --- a/extopy-commons/src/commonMain/kotlin/me/nathanfallet/extopy/models/auth/RegisterCodePayload.kt +++ b/extopy-commons/src/commonMain/kotlin/me/nathanfallet/extopy/models/auth/RegisterCodePayload.kt @@ -2,11 +2,15 @@ package me.nathanfallet.extopy.models.auth import kotlinx.datetime.LocalDate import kotlinx.serialization.Serializable +import me.nathanfallet.extopy.models.users.User +import me.nathanfallet.usecases.models.annotations.validators.StringPropertyValidator @Serializable data class RegisterCodePayload( val password: String, + @StringPropertyValidator(regex = User.USERNAME_REGEX, maxLength = 25) val username: String, + @StringPropertyValidator(maxLength = 40) val displayName: String, val birthdate: LocalDate, )