aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrubenwardy <rw@rubenwardy.com>2020-09-22 21:53:04 +0100
committerrubenwardy <rw@rubenwardy.com>2020-09-22 21:53:04 +0100
commit2aa0c3cc844e873851e752693366a38a25c75e46 (patch)
tree2618e6d6dfe8004a682d293332a33b00ac216283
parenta3b3525b7879e3ba7efcc06a9bdc9065fccf0be5 (diff)
downloadcheatdb-2aa0c3cc844e873851e752693366a38a25c75e46.tar.xz
Fix texture pack license not present issue
Fixes #236
-rw-r--r--app/blueprints/packages/packages.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/app/blueprints/packages/packages.py b/app/blueprints/packages/packages.py
index c79e931..0634a77 100644
--- a/app/blueprints/packages/packages.py
+++ b/app/blueprints/packages/packages.py
@@ -289,6 +289,9 @@ def create_edit(author=None, name=None):
form.tags.data = list(package.tags)
form.content_warnings.data = list(package.content_warnings)
+ if request.method == "POST" and form.type.data == PackageType.TXP:
+ form.license.data = form.media_license.data
+
if request.method == "POST" and form.validate():
wasNew = False
if not package: