lib/adiwg/mdtranslator/writers/html/sections/html_timePeriod.rb in adiwg-mdtranslator-1.2.1 vs lib/adiwg/mdtranslator/writers/html/sections/html_timePeriod.rb in adiwg-mdtranslator-1.3.0
- old
+ new
@@ -1,12 +1,13 @@
# HTML writer
# time period
# History:
# Stan Smith 2015-03-23 original script
+# Stan Smith 2015-07-16 refactored to remove global namespace $HtmlNS
-require 'html_dateTime'
+require_relative 'html_dateTime'
module ADIWG
module Mdtranslator
module Writers
module Html
@@ -17,10 +18,10 @@
end
def writeHtml(hTimePeriod)
# classes used
- htmlDateTime = $HtmlNS::MdHtmlDateTime.new(@html)
+ htmlDateTime = MdHtmlDateTime.new(@html)
# timePeriod - id
s = hTimePeriod[:timeId]
if !s.nil?
@html.em('ID: ')