diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2011-03-14 13:10:11 +0100 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2011-03-14 13:10:11 +0100 |
commit | 40fedb850e110bb06018742e217cfda577a0d6a8 (patch) | |
tree | 2d563e0d738c61a5be87c8f84e8c218a1a8a922e /module/web/json_app.py | |
parent | fixes last commit (diff) | |
download | pyload-40fedb850e110bb06018742e217cfda577a0d6a8.tar.xz |
new ul plugin
Diffstat (limited to 'module/web/json_app.py')
-rw-r--r-- | module/web/json_app.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/module/web/json_app.py b/module/web/json_app.py index ac1f3ec9c..df58238ec 100644 --- a/module/web/json_app.py +++ b/module/web/json_app.py @@ -211,7 +211,7 @@ def link_order(ids): @route("/json/add_package", method="POST") @login_required('add') def add_package(): - name = request.forms.get("add_name", "New Package") + name = request.forms.get("add_name", "New Package").strip() queue = int(request.forms['add_dest']) links = request.forms['add_links'].decode("utf8", "ignore") links = links.split("\n") @@ -220,7 +220,7 @@ def add_package(): try: f = request.files['add_file'] - if name == "New Package": + if not name or name == "New Package": name = f.name fpath = join(PYLOAD.get_conf_val("general", "download_folder"), "tmp_" + f.filename) |