From 9af2476cd974bc0201f3b13637c3f337f26dc888 Mon Sep 17 00:00:00 2001 From: Jorran de Wit <jorrandewit@outlook.com> Date: Sat, 9 Sep 2017 12:53:48 +0200 Subject: [PATCH] Fix preceeding reports filter --- submissions/models.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/submissions/models.py b/submissions/models.py index 4a7e33cb1..fac326dd3 100644 --- a/submissions/models.py +++ b/submissions/models.py @@ -431,7 +431,8 @@ class Report(SubmissionRelatedObjectMixin, models.Model): author of the report already has a vetted report in the series of the specific Submission. """ return (self.author.reports.accepted() - .filter(submission__arxiv_identifier_wo_vn_nr=self.submission.arxiv_identifier_wo_vn_nr) + .filter(submission__arxiv_identifier_wo_vn_nr=self.submission.arxiv_identifier_wo_vn_nr, + submission__arxiv_vn_nr__lt=self.submission.arxiv_vn_nr) .exists()) def latest_report_from_series(self): -- GitLab