summaryrefslogtreecommitdiff
path: root/lib/util.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2009-02-11 00:45:11 -0500
committerEvan Prodromou <evan@controlyourself.ca>2009-02-11 00:45:11 -0500
commitbba1dbdb403aac067ae97c44531f6886f90fec35 (patch)
tree32ff8ae70721baf721ab4833acc2abfe7fff07c2 /lib/util.php
parentfbecbcb693e9d8fc810cf316e8739a22ac501043 (diff)
Use a router singleton
Diffstat (limited to 'lib/util.php')
-rw-r--r--lib/util.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/util.php b/lib/util.php
index a78af8be9..9b38b5596 100644
--- a/lib/util.php
+++ b/lib/util.php
@@ -669,8 +669,12 @@ function common_relative_profile($sender, $nickname, $dt=null)
function common_local_url($action, $args=null, $fragment=null)
{
- $r = new Router();
+ common_debug("Action = $action, args = " . (($args) ? '(' . implode($args, ',') . ')' : $args) . ", fragment = $fragment");
+ $r = Router::get();
+ $start = microtime();
$path = $r->build($action, $args, $fragment);
+ $end = microtime();
+ common_debug("Pathbuilding took " . ($end - $start));
if ($path) {
}
if (common_config('site','fancy')) {