X-Git-Url: https://code.wpia.club/?p=gigi.git;a=blobdiff_plain;f=src%2Fclub%2Fwpia%2Fgigi%2Futil%2FNotary.java;h=36f1fa48c3c603c3c1dd5ed7ab3a30437bf5d2a1;hp=da80752259cbf9c6edf01043ccefaa4c97b04129;hb=0d5ae34e23b50f59e759702b1ebf6f5a3a7137f4;hpb=a1fb2906862d4edc566a49d5a6c9133cffcfba68 diff --git a/src/club/wpia/gigi/util/Notary.java b/src/club/wpia/gigi/util/Notary.java index da807522..36f1fa48 100644 --- a/src/club/wpia/gigi/util/Notary.java +++ b/src/club/wpia/gigi/util/Notary.java @@ -45,7 +45,7 @@ public class Notary { } public static boolean checkVerificationIsPossible(User agent, Name target) { - try (GigiPreparedStatement ps = new GigiPreparedStatement("SELECT 1 FROM `notary` where `to`=? and `from`=? and `method` = ? ::`notaryType` AND `deleted` IS NULL AND `when` > (now() - interval '1 days' * ?)")) { + try (GigiPreparedStatement ps = new GigiPreparedStatement("SELECT 1 FROM `notary` where `to`=? and `from`=? and `method` = ? ::`notaryType` AND `deleted` IS NULL AND `when` > (now() - interval '1 days' * ?::INTEGER)")) { ps.setInt(1, target.getId()); ps.setInt(2, agent.getId()); ps.setEnum(3, VerificationType.FACE_TO_FACE);