class Asciidoctor::Document

def doctitle

We need to be able to return some semblance of a title
def doctitle
  if !(title = @attributes.fetch('title', '')).empty?
    title
  elsif !(sect = first_section).nil? && sect.title?
    sect.title
  else
    nil
  end
end