about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2015-10-30 19:44:41 +0000
committerEric Wong <e@80x24.org>2015-10-30 19:44:41 +0000
commitc09ce908da64f03c671f483750ce28dcecc064ac (patch)
tree83a400b99ae154d6eff9b3bc6610add5e73499b7
parent7b1af74af6d8d563bd302fcf25fe576760507a6e (diff)
downloadolddoc-c09ce908da64f03c671f483750ce28dcecc064ac.tar.gz
We must explicitly convert Pathname to string before comparing
against '.' to prevent ugly './' prefixes in relative paths from
showing up.
-rw-r--r--lib/oldweb.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/oldweb.rb b/lib/oldweb.rb
index d045693..12ce876 100644
--- a/lib/oldweb.rb
+++ b/lib/oldweb.rb
@@ -92,7 +92,7 @@ class Oldweb
 
   def rel_path(out_file)
     rel_prefix = @outputdir.relative_path_from(out_file.dirname)
-    rel_prefix == '.' ? '' : "#{rel_prefix}/"
+    rel_prefix.to_s == '.' ? '' : "#{rel_prefix}/"
   end
 
   # called standalone by servelet