fix for titles coming from subdir indexes

This commit is contained in:
Kyle Drake 2015-01-16 17:10:37 -08:00
parent 8ed3183c5f
commit 70f2057854
2 changed files with 15 additions and 2 deletions

View file

@ -567,7 +567,7 @@ class Site < Sequel::Model
}
end
if pathname.basename.to_s == 'index.html' && opts[:new_install] != true
if relative_path == 'index.html' && opts[:new_install] != true
begin
new_title = Nokogiri::HTML(File.read(uploaded.path)).css('title').first.text
rescue NoMethodError => e