]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
add sup with arguments
authorEvan Prodromou <evan@controlyourself.ca>
Wed, 1 Apr 2009 22:29:10 +0000 (18:29 -0400)
committerEvan Prodromou <evan@controlyourself.ca>
Wed, 1 Apr 2009 22:29:10 +0000 (18:29 -0400)
actions/sup.php
lib/router.php

index 8ef9207facce41d02ac44d00ce771ec38df39720..246b3299d32e975db9faa02648a3b18cade8335e 100644 (file)
@@ -45,7 +45,7 @@ class SupAction extends Action
     function availablePeriods()
     {
         static $periods = array(86400, 43200, 21600, 7200,
-                                3600, 1800,    600, 300, 120,
+                                3600, 1800, 600, 300, 120,
                                 60, 30, 15);
         $available = array();
         foreach ($periods as $period) {
index ae5b5e16bdf0bbd8b2a9aad9d641a6cf99660815..6fb2f94872cbbc3386ecceaad00bc21349cd6352 100644 (file)
@@ -107,6 +107,9 @@ class Router
             $m->connect('main/'.$a, array('action' => $a));
         }
 
+        $m->connect('main/sup/:seconds', array('action' => 'sup'),
+                    array('seconds' => '[0-9]+'));
+
         $m->connect('main/tagother/:id', array('action' => 'tagother'));
 
         // these take a code