aboutsummaryrefslogtreecommitdiffstats
path: root/mediagoblin/plugins/piwigo/views.py
diff options
context:
space:
mode:
Diffstat (limited to 'mediagoblin/plugins/piwigo/views.py')
-rw-r--r--mediagoblin/plugins/piwigo/views.py8
1 files changed, 2 insertions, 6 deletions
diff --git a/mediagoblin/plugins/piwigo/views.py b/mediagoblin/plugins/piwigo/views.py
index 1c655bf5..bd6b1012 100644
--- a/mediagoblin/plugins/piwigo/views.py
+++ b/mediagoblin/plugins/piwigo/views.py
@@ -26,7 +26,7 @@ from mediagoblin.meddleware.csrf import csrf_exempt
from mediagoblin.auth.lib import fake_login_attempt
from mediagoblin.media_types import sniff_media
from mediagoblin.submit.lib import check_file_field, prepare_queue_task, \
- run_process_media
+ run_process_media, new_upload_entry
from .tools import CmdTable, response_xml, check_form, \
PWGSession, PwgNamedArray, PwgError
@@ -124,7 +124,7 @@ def pwg_images_addSimple(request):
request.files['image'])
# create entry and save in database
- entry = request.db.MediaEntry()
+ entry = new_upload_entry(request.user)
entry.media_type = unicode(media_type)
entry.title = (
unicode(form.name.data)
@@ -132,10 +132,6 @@ def pwg_images_addSimple(request):
entry.description = unicode(form.comment.data)
- # entry.license = unicode(form.license.data) or None
-
- entry.uploader = request.user.id
-
'''
# Process the user's folksonomy "tags"
entry.tags = convert_to_tag_list_of_dicts(