]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/showfavorites.php
you can _so_ leave a group if you're its admin
[quix0rs-gnu-social.git] / actions / showfavorites.php
index bb68f8d94f6d69f2336301c451b4fc2f305d2911..d1c9283f0f47bff1a6811039a891760898de3f87 100644 (file)
@@ -112,6 +112,8 @@ class ShowfavoritesAction extends Action
             $this->page = 1;
         }
 
+        common_set_returnto($this->selfUrl());
+
         return true;
     }
 
@@ -134,10 +136,10 @@ class ShowfavoritesAction extends Action
     /**
      * Feeds for the <head> section
      *
-     * @return void
+     * @return array Feed objects to show
      */
 
-    function showFeeds()
+    function getFeeds()
     {
         $feedurl   = common_local_url('favoritesrss',
                                       array('nickname' =>
@@ -145,10 +147,7 @@ class ShowfavoritesAction extends Action
         $feedtitle = sprintf(_('Feed for favorites of %s'),
                              $this->user->nickname);
 
-        $this->element('link', array('rel' => 'alternate',
-                                     'href' => $feedurl,
-                                     'type' => 'application/rss+xml',
-                                     'title' => $feedtitle));
+        return array(new Feed(Feed::RSS1, $feedurl, $feedtitle));
     }
 
     /**
@@ -163,28 +162,6 @@ class ShowfavoritesAction extends Action
         $nav->show();
     }
 
-    /**
-     * Show the replies feed links
-     *
-     * @return void
-     */
-
-    function showExportData()
-    {
-        $feedurl = common_local_url('favoritesrss',
-                                    array('nickname' =>
-                                          $this->user->nickname));
-
-        $fl = new FeedList($this);
-
-        // XXX: I18N
-
-        $fl->show(array(0=>array('href'=> $feedurl,
-                                 'type' => 'rss',
-                                 'version' => 'RSS 1.0',
-                                 'item' => 'Favorites')));
-    }
-
     /**
      * Show the content
      *