fix issue searching rule by debt (with @julienlancelot)