diff --git a/config/build/pos2htmls b/config/build/pos2htmls
index b5a36fd..96b5459 100755
--- a/config/build/pos2htmls
+++ b/config/build/pos2htmls
@@ -69,9 +69,6 @@ Dir.glob(po_dir + '*/*.po').each do |po|
hash['content'].map!{|l| l.gsub('\\n', "\n")}
- # Gets the title
- hash['title'] = hash['content'][0].gsub(/^#\s+/, '').gsub(/\n\n/, '').strip
-
# Creates locale folder if it doesn't exists
if !File.directory?(html_dir + hash['locale'])
Dir.mkdir(html_dir + hash['locale'])
@@ -90,6 +87,14 @@ Dir.glob(po_dir + '*/*.po').each do |po|
system("pc-pandog -i #{md_name} -o #{html_name}")
FileUtils.rm(md_name)
+ # Gets the title
+ hash['title'] = File.read(html_name)
+ .gsub(/\n/, '')
+ .gsub(/