Let's redirect back to the media homepage using the slug instead of the id
authorChristopher Allan Webber <cwebber@dustycloud.org>
Sat, 4 Jun 2011 13:48:17 +0000 (08:48 -0500)
committerChristopher Allan Webber <cwebber@dustycloud.org>
Sat, 4 Jun 2011 13:48:17 +0000 (08:48 -0500)
mediagoblin/edit/views.py

index c3aedac94490d11f6da965666e028ad0d015e165..0e0faa53fdfa137c75f387f975af7aace1a79781 100644 (file)
@@ -53,7 +53,7 @@ def edit_media(request, media):
             # redirect
             return exc.HTTPFound(
                 location=request.urlgen("mediagoblin.user_pages.media_home",
-                    user=media.uploader()['username'], media=media['_id']))
+                    user=media.uploader()['username'], media=media['slug']))
 
     # render
     template = request.template_env.get_template(