mirror of
https://github.com/minetest/contentdb.git
synced 2024-11-09 17:13:45 +01:00
Fix error on double "move_to_state" submission
This commit is contained in:
parent
9a64ff7563
commit
0c4698ec0d
@ -400,6 +400,9 @@ def move_to_state(package):
|
||||
if state is None:
|
||||
abort(400)
|
||||
|
||||
if package.state == state:
|
||||
return redirect(package.get_url("packages.view"))
|
||||
|
||||
if not can_move_to_state(package, current_user, state):
|
||||
flash(gettext("You don't have permission to do that"), "danger")
|
||||
return redirect(package.get_url("packages.view"))
|
||||
|
Loading…
Reference in New Issue
Block a user