summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--actions/twitapistatuses.php2
-rw-r--r--actions/userrss.php11
-rw-r--r--lib/router.php4
-rw-r--r--lib/util.php4
4 files changed, 10 insertions, 11 deletions
diff --git a/actions/twitapistatuses.php b/actions/twitapistatuses.php
index 18e24c0f5..51c256589 100644
--- a/actions/twitapistatuses.php
+++ b/actions/twitapistatuses.php
@@ -204,7 +204,7 @@ class TwitapistatusesAction extends TwitterapiAction
# FriendFeed's SUP protocol
# Also added RSS and Atom feeds
- $suplink = common_local_url('sup', null, $user->id);
+ $suplink = common_local_url('sup', null, null, $user->id);
header('X-SUP-ID: '.$suplink);
# XXX: since
diff --git a/actions/userrss.php b/actions/userrss.php
index 04855ccca..a3e5a3aab 100644
--- a/actions/userrss.php
+++ b/actions/userrss.php
@@ -46,13 +46,13 @@ class UserrssAction extends Rss10Action
{
$user = $this->user;
-
+
if (is_null($user)) {
return null;
}
-
+
$notice = $user->getNotices(0, ($limit == 0) ? NOTICES_PER_PAGE : $limit);
-
+
while ($notice->fetch()) {
$notices[] = clone($notice);
}
@@ -87,10 +87,10 @@ class UserrssAction extends Rss10Action
}
# override parent to add X-SUP-ID URL
-
+
function initRss($limit=0)
{
- $url = common_local_url('sup', null, $this->user->id);
+ $url = common_local_url('sup', null, null, $this->user->id);
header('X-SUP-ID: '.$url);
parent::initRss($limit);
}
@@ -100,4 +100,3 @@ class UserrssAction extends Rss10Action
return true;
}
}
-
diff --git a/lib/router.php b/lib/router.php
index 0640a5911..85425bed2 100644
--- a/lib/router.php
+++ b/lib/router.php
@@ -350,7 +350,7 @@ class Router
return $this->m->match($path);
}
- function build($action, $args=null, $fragment=null)
+ function build($action, $args=null, $params=null, $fragment=null)
{
$action_arg = array('action' => $action);
@@ -360,6 +360,6 @@ class Router
$args = $action_arg;
}
- return $this->m->generate($args, null, $fragment);
+ return $this->m->generate($args, $params, $fragment);
}
} \ No newline at end of file
diff --git a/lib/util.php b/lib/util.php
index 46aa7b9df..5345a08bb 100644
--- a/lib/util.php
+++ b/lib/util.php
@@ -705,10 +705,10 @@ function common_relative_profile($sender, $nickname, $dt=null)
return null;
}
-function common_local_url($action, $args=null, $fragment=null)
+function common_local_url($action, $args=null, $params=null, $fragment=null)
{
$r = Router::get();
- $path = $r->build($action, $args, $fragment);
+ $path = $r->build($action, $args, $params, $fragment);
if ($path) {
}
if (common_config('site','fancy')) {