GUACAMOLE-525: Quick tweak to logic in password history file.

This commit is contained in:
Nick Couchman
2018-03-13 22:34:21 -04:00
parent 62a706896a
commit c062acea2d

View File

@@ -65,7 +65,8 @@
); );
DELETE FROM [guacamole_user_password_history] DELETE FROM [guacamole_user_password_history]
WHERE password_history_id NOT IN ( WHERE user_id = #{record.userID,jdbcType=INTEGER}
AND password_history_id NOT IN (
SELECT TOP(#{maxHistorySize}) password_history_id SELECT TOP(#{maxHistorySize}) password_history_id
FROM [guacamole_user_password_history] FROM [guacamole_user_password_history]
WHERE user_id = #{record.userID,jdbcType=INTEGER} WHERE user_id = #{record.userID,jdbcType=INTEGER}