User accounts can now be disabled

This commit is contained in:
neviyn 2021-04-29 00:41:58 +01:00
parent 935f283589
commit 89b798e32d
2 changed files with 4 additions and 1 deletions

View File

@ -16,6 +16,9 @@ open class User(
open var email: String = "", open var email: String = "",
@JsonIgnore @JsonIgnore
open var password: String = "", open var password: String = "",
@JsonIgnore
open var enabled: Boolean = true,
@JsonIgnore
@ManyToMany @ManyToMany
@JoinTable( @JoinTable(
name = "user_roles", name = "user_roles",

View File

@ -43,7 +43,7 @@ class CustomUserDetails(private val user: User) : UserDetails {
override fun isCredentialsNonExpired(): Boolean = true override fun isCredentialsNonExpired(): Boolean = true
override fun isEnabled(): Boolean = true override fun isEnabled(): Boolean = user.enabled
} }