Added check for archived patron
This commit is contained in:
@@ -80,7 +80,7 @@ class PatronService(private val connection: Connection) {
|
|||||||
statement.setString(1, username)
|
statement.setString(1, username)
|
||||||
val resultSet = statement.executeQuery()
|
val resultSet = statement.executeQuery()
|
||||||
return if (resultSet.next()) {
|
return if (resultSet.next()) {
|
||||||
resultSet.getString("password") == password
|
resultSet.getString("password") == password && !resultSet.getBoolean("is_archived")
|
||||||
} else {
|
} else {
|
||||||
throw SQLException()
|
throw SQLException()
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user