Tweaked a log.assertion() case.
- Legacy-Id: 17793
This commit is contained in:
parent
b53d78a0ad
commit
3439f3d42c
|
@ -133,7 +133,7 @@ def validate_submission_rev(name, rev):
|
|||
|
||||
expected = 0
|
||||
existing_revs = [int(i.rev) for i in Document.objects.filter(name=name) if i.rev and i.rev.isdigit() ]
|
||||
unexpected_revs = [ i.rev for i in Document.objects.filter(name=name) if not (i.rev and i.rev.isdigit()) ] # pyflakes:ignore
|
||||
unexpected_revs = [ i.rev for i in Document.objects.filter(name=name) if i.rev and not i.rev.isdigit() ] # pyflakes:ignore
|
||||
log.assertion('unexpected_revs', [])
|
||||
if existing_revs:
|
||||
expected = max(existing_revs) + 1
|
||||
|
|
Loading…
Reference in a new issue