Fix deleted packaging being show on todo page

Fixes #401
This commit is contained in:
rubenwardy 2023-01-02 19:16:51 +00:00
parent 38baea3dcf
commit 31a748b0b3

@ -178,7 +178,8 @@ def view_user(username=None):
~Package.screenshots.any(), Package.state == PackageState.APPROVED).all()
packages_with_small_screenshots = user.maintained_packages \
.filter(Package.screenshots.any(and_(PackageScreenshot.width < PackageScreenshot.SOFT_MIN_SIZE[0],
.filter(Package.state != PackageState.DELETED,
Package.screenshots.any(and_(PackageScreenshot.width < PackageScreenshot.SOFT_MIN_SIZE[0],
PackageScreenshot.height < PackageScreenshot.SOFT_MIN_SIZE[1]))) \
.all()