Allow API client to GET another user's outbox
authorayleph <ayleph@thisshitistemp.com>
Sat, 31 Oct 2015 08:18:44 +0000 (04:18 -0400)
committerJessica Tallon <tsyesika@tsyesika.se>
Tue, 24 Nov 2015 10:00:26 +0000 (10:00 +0000)
Signed-off-by: Jessica Tallon <tsyesika@tsyesika.se>
mediagoblin/api/views.py

index 671c3b360ce40bd48d1e32914977d6606f9d5c4f..dcd04cd6151503578cfc31ffe1806262ef263b59 100644 (file)
@@ -565,9 +565,9 @@ def feed_endpoint(request, outbox=None):
 
     # Create outbox
     if outbox is None:
-        outbox = Activity.query.filter_by(actor=request.user.id)
+        outbox = Activity.query.filter_by(actor=requested_user.id)
     else:
-        outbox = outbox.filter_by(actor=request.user.id)
+        outbox = outbox.filter_by(actor=requested_user.id)
 
     # We want the newest things at the top (issue: #1055)
     outbox = outbox.order_by(Activity.published.desc())