mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
fix: produce DeleteNotification a line before handle_request
With this on a single line, the argument ordering and class/func execution was a bit too RNG causing exceptions to be thrown when producing a notification based off of a deleted pkgbase object. Signed-off-by: Kevin Morris <kevr@0cost.org>
This commit is contained in:
parent
624954042b
commit
37c7dee099
1 changed files with 2 additions and 3 deletions
|
@ -99,9 +99,8 @@ def pkgbase_adopt_instance(request: Request, pkgbase: PackageBase) -> None:
|
|||
def pkgbase_delete_instance(
|
||||
request: Request, pkgbase: PackageBase, comments: str = str()
|
||||
) -> list[notify.Notification]:
|
||||
notifs = handle_request(request, DELETION_ID, pkgbase) + [
|
||||
notify.DeleteNotification(request.user.ID, pkgbase.ID)
|
||||
]
|
||||
notif = notify.DeleteNotification(request.user.ID, pkgbase.ID)
|
||||
notifs = handle_request(request, DELETION_ID, pkgbase) + [notif]
|
||||
|
||||
with db.begin():
|
||||
update_closure_comment(pkgbase, DELETION_ID, comments)
|
||||
|
|
Loading…
Add table
Reference in a new issue