diff options
author | Joey Hess <joey@kodama.kitenet.net> | 2008-10-01 17:29:03 -0400 |
---|---|---|
committer | Joey Hess <joey@kodama.kitenet.net> | 2008-10-01 17:29:03 -0400 |
commit | bf386e22f5fb65999c38668cb011bdf4ae26d72c (patch) | |
tree | 7bb0c075e343e211c540b6af51658b98776ab502 /IkiWiki/Plugin | |
parent | f2b1a918b022863c6baf010bee3e57b5f08a794f (diff) |
inline: Fix handling of rootpage that doesn't exist.
It makes sense to use bestlink to determine which page rootpage refers to,
but if no page matches, just use the raw value.
Diffstat (limited to 'IkiWiki/Plugin')
-rw-r--r-- | IkiWiki/Plugin/inline.pm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/IkiWiki/Plugin/inline.pm b/IkiWiki/Plugin/inline.pm index e0f33ef31..5d2ef5681 100644 --- a/IkiWiki/Plugin/inline.pm +++ b/IkiWiki/Plugin/inline.pm @@ -266,6 +266,9 @@ sub preprocess_inline (@) { #{{{ my $rootpage; if (exists $params{rootpage}) { $rootpage=bestlink($params{page}, $params{rootpage}); + if (!length $rootpage) { + $rootpage=$params{rootpage}; + } } else { $rootpage=$params{page}; |