Loading lib/jsduck/logger.rb +1 −0 Original line number Diff line number Diff line Loading @@ -37,6 +37,7 @@ module JsDuck [:cat_no_match, "Class pattern in categories file matches nothing"], [:cat_class_missing, "Class is missing from categories file"], [:guide, "Guide is missing from --guides dir"], [:aside, "Problem with @aside tag"], ] # Turn off all warnings by default. # This is good for testing. Loading lib/jsduck/tag/aside.rb +7 −5 Original line number Diff line number Diff line Loading @@ -34,11 +34,6 @@ module JsDuck::Tag end.compact end def warn(msg) JsDuck::Logger.instance.warn(nil, msg) nil end def to_html(asides) asides.map do |aside| asset = get_asset(aside[:type], aside[:name]) Loading @@ -61,6 +56,13 @@ module JsDuck::Tag else nil end end def warn(msg) ctx = @context ? @context[:files][0] : {} JsDuck::Logger.instance.warn(:aside, msg, ctx[:filename], ctx[:linenr]) nil end end end Loading
lib/jsduck/logger.rb +1 −0 Original line number Diff line number Diff line Loading @@ -37,6 +37,7 @@ module JsDuck [:cat_no_match, "Class pattern in categories file matches nothing"], [:cat_class_missing, "Class is missing from categories file"], [:guide, "Guide is missing from --guides dir"], [:aside, "Problem with @aside tag"], ] # Turn off all warnings by default. # This is good for testing. Loading
lib/jsduck/tag/aside.rb +7 −5 Original line number Diff line number Diff line Loading @@ -34,11 +34,6 @@ module JsDuck::Tag end.compact end def warn(msg) JsDuck::Logger.instance.warn(nil, msg) nil end def to_html(asides) asides.map do |aside| asset = get_asset(aside[:type], aside[:name]) Loading @@ -61,6 +56,13 @@ module JsDuck::Tag else nil end end def warn(msg) ctx = @context ? @context[:files][0] : {} JsDuck::Logger.instance.warn(:aside, msg, ctx[:filename], ctx[:linenr]) nil end end end