aboutsummaryrefslogtreecommitdiffstats
path: root/mediagoblin/edit/views.py
diff options
context:
space:
mode:
authorsaksham1115 <saksham115@gmail.com>2016-07-13 13:48:52 +0000
committersaksham1115 <saksham115@gmail.com>2016-07-19 17:29:24 +0000
commitdef53bc3ed189b2e9928b4046a3c2c8a61e31d59 (patch)
tree6eccce26781108a8d5fbaac03f4361f4ef6204d7 /mediagoblin/edit/views.py
parent4292c6aaaa1fb49740ecd0a26946f2460d805e46 (diff)
downloadmediagoblin-def53bc3ed189b2e9928b4046a3c2c8a61e31d59.tar.lz
mediagoblin-def53bc3ed189b2e9928b4046a3c2c8a61e31d59.tar.xz
mediagoblin-def53bc3ed189b2e9928b4046a3c2c8a61e31d59.zip
Only video owner can upload the subtitle for the video
Diffstat (limited to 'mediagoblin/edit/views.py')
-rw-r--r--mediagoblin/edit/views.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/mediagoblin/edit/views.py b/mediagoblin/edit/views.py
index 9ab4a60c..6b22fbae 100644
--- a/mediagoblin/edit/views.py
+++ b/mediagoblin/edit/views.py
@@ -34,7 +34,7 @@ from mediagoblin.edit.lib import may_edit_media
from mediagoblin.decorators import (require_active_login, active_user_from_url,
get_media_entry_by_id, user_may_alter_collection,
get_user_collection, user_has_privilege,
- user_not_banned, path_subtitle)
+ user_not_banned, path_subtitle, user_may_delete_media)
from mediagoblin.tools.crypto import get_timed_signer_url
from mediagoblin.tools.metadata import (compact_and_validate, DEFAULT_CHECKER,
DEFAULT_SCHEMA)
@@ -182,6 +182,7 @@ def edit_attachments(request, media):
raise Forbidden("Attachments are disabled")
@get_media_entry_by_id
+@user_may_delete_media
@require_active_login
def edit_subtitles(request, media):
if mg_globals.app_config['allow_subtitles']: