From ba5ea989a5826440e8b84af8128dadd0ae252259 Mon Sep 17 00:00:00 2001 From: Sebastian Spaeth Date: Thu, 17 Jan 2013 22:37:41 +0100 Subject: [PATCH] Return to media collection page if no collection selected schendje rightly pointed out that we should not return to the media homepage if we did not select a collection on the "collect" page, but should actually return to the collect page. This is an improvement of the user experience ;-) Signed-off-by: Sebastian Spaeth --- mediagoblin/user_pages/views.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mediagoblin/user_pages/views.py b/mediagoblin/user_pages/views.py index 30c78a38..d1ec23dc 100644 --- a/mediagoblin/user_pages/views.py +++ b/mediagoblin/user_pages/views.py @@ -226,6 +226,10 @@ def media_collect(request, media): messages.add_message( request, messages.ERROR, _('You have to select or add a collection')) + return redirect(request, "mediagoblin.user_pages.media_collect", + user=media.get_uploader.username, + media=media.id) + # Check whether media already exists in collection elif CollectionItem.query.filter_by( -- 2.25.1