diff options
author | Joey Hess <joey@kodama.kitenet.net> | 2008-07-11 09:52:17 -0400 |
---|---|---|
committer | Joey Hess <joey@kodama.kitenet.net> | 2008-07-11 09:52:17 -0400 |
commit | 810a355308d276ef922ff4312bff0c7935676633 (patch) | |
tree | 4273f5ca6e5af802f12bb99baeac3c01b9c24299 | |
parent | d5de560f50cee1b3f7facb4a7b53d90556ec091c (diff) |
Revert "Fix a bug with links to pages whose names contained colons."
This reverts commit e25c3a0a7caa9783c657efe86611929ecb7bd4a3.
I didn't think that through far enough; beautify_url may be called on full
urls, which don't start with "/"!
Conflicts:
debian/changelog
-rw-r--r-- | IkiWiki.pm | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/IkiWiki.pm b/IkiWiki.pm index 6e03121c0..4368870b8 100644 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@ -539,12 +539,7 @@ sub beautify_url ($) { #{{{ if ($config{usedirs}) { $url =~ s!/index.$config{htmlext}$!/!; } - - # Ensure url is not an empty link, and - # if it's relative, make that explicit to avoid colon confusion. - if ($url !~ /\//) { - $url="./$url"; - } + $url =~ s!^$!./!; # Browsers don't like empty links... return $url; } #}}} |