Skip to content

Commit

Permalink
Fixed syntax issue with h2 upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
skavanagh committed Feb 13, 2022
1 parent 7bd4208 commit 62bc1d2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/io/bastillion/manage/db/PublicKeyDB.java
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ public static boolean isKeyRegistered(Long userId, PublicKey publicKey) throws S
boolean isDuplicate = false;
Connection con = DBUtils.getConn();

PreparedStatement stmt = con.prepareStatement("select * from public_keys where user_id=? and fingerprint like ? and profile_id is ? and id is not ?");
PreparedStatement stmt = con.prepareStatement("select * from public_keys where user_id=? and fingerprint like ? and profile_id = ? and id <> ?");
stmt.setLong(1, userId);
stmt.setString(2, SSHUtil.getFingerprint(publicKey.getPublicKey()));
if (publicKey.getProfile() != null && publicKey.getProfile().getId() != null) {
Expand Down

0 comments on commit 62bc1d2

Please sign in to comment.