]> sipb.mit.edu Git - ikiwiki.git/blobdiff - plugins/externaldemo
doc/po: follow-up
[ikiwiki.git] / plugins / externaldemo
index fa93e672d86f24c1e253d20717e4c09b19109be1..be7aba8b929807db3a6b56a6846e7d34b3c79a25 100755 (executable)
@@ -101,16 +101,15 @@ sub import {
        # stage of ikiwiki.
        rpc_call("hook", type => "preprocess", id => "externaldemo", call => "preprocess");
 
        # stage of ikiwiki.
        rpc_call("hook", type => "preprocess", id => "externaldemo", call => "preprocess");
 
-       # Here's an example of how to inject an arbitrary function into
-       # ikiwiki. Ikiwiki will be able to call bob() just like any other
-       # function. Note use of automatic memoization.
-       rpc_call("inject", name => "IkiWiki::bob", call => "bob",
-               memoize => 1);
-
        # Here's an exmaple of how to access values in %IkiWiki::config.
        print STDERR "url is set to: ".
                rpc_call("getvar", "config", "url")."\n";
 
        # Here's an exmaple of how to access values in %IkiWiki::config.
        print STDERR "url is set to: ".
                rpc_call("getvar", "config", "url")."\n";
 
+       # Here's an example of how to inject an arbitrary function into
+       # ikiwiki. Note use of automatic memoization.
+       rpc_call("inject", name => "IkiWiki::bob",
+               call => "formattime", memoize => 1);
+
        print STDERR "externaldemo plugin successfully imported\n";
 }
 
        print STDERR "externaldemo plugin successfully imported\n";
 }