mirror of
https://github.com/minetest/contentdb.git
synced 2024-12-23 06:22:24 +01:00
Show message on draft packages rather than 404
This commit is contained in:
parent
a7e6f19ae6
commit
16abb636c5
@ -117,9 +117,6 @@ def getReleases(package):
|
|||||||
@is_package_page
|
@is_package_page
|
||||||
def view(package):
|
def view(package):
|
||||||
if package.state != PackageState.APPROVED and not package.checkPerm(current_user, Permission.EDIT_PACKAGE):
|
if package.state != PackageState.APPROVED and not package.checkPerm(current_user, Permission.EDIT_PACKAGE):
|
||||||
if package.state == PackageState.WIP:
|
|
||||||
abort(404)
|
|
||||||
|
|
||||||
return render_template("packages/gone.html", package=package), 503
|
return render_template("packages/gone.html", package=package), 503
|
||||||
|
|
||||||
show_similar = not package.approved and (
|
show_similar = not package.approved and (
|
||||||
|
@ -26,6 +26,11 @@
|
|||||||
<p>
|
<p>
|
||||||
{{ _("This package is currently undergoing review") }}
|
{{ _("This package is currently undergoing review") }}
|
||||||
</p>
|
</p>
|
||||||
|
{% elif package.state.name == "WIP" %}
|
||||||
|
<h1>{{ _("Package Not Yet Submitted") }}</h1>
|
||||||
|
<p>
|
||||||
|
{{ _("This package has been created but hasn't been submitted for approval yet.") }}
|
||||||
|
</p>
|
||||||
{% else %}
|
{% else %}
|
||||||
<h1>{{ _("Package Undergoing Review") }}</h1>
|
<h1>{{ _("Package Undergoing Review") }}</h1>
|
||||||
<p>
|
<p>
|
||||||
|
Loading…
Reference in New Issue
Block a user