Merge commit 'smcv/recentchanges'

master
Joey Hess 2008-12-22 19:02:03 -05:00
commit aa603888d2
1 changed files with 9 additions and 0 deletions

View File

@ -95,6 +95,15 @@ sub cgi ($) {
IkiWiki::loadindex();
# If the page is internal (like a comment), see if it has a
# permalink. Comments do.
if (IkiWiki::isinternal($page) &&
defined $pagestate{$page}{meta}{permalink}) {
IkiWiki::redirect($cgi,
$pagestate{$page}{meta}{permalink});
exit;
}
my $link=bestlink("", $page);
if (! length $link) {
print "Content-type: text/html\n\n";