lib/adiwg/mdtranslator.rb in adiwg-mdtranslator-0.12.0 vs lib/adiwg/mdtranslator.rb in adiwg-mdtranslator-0.12.1

- old
+ new

@@ -77,15 +77,15 @@ return $response end end # handle writers - if writer - require File.join(File.dirname(__FILE__), 'mdtranslator/writers/mdWriters') - ADIWG::Mdtranslator::Writers.handleWriter(intObj) - else + if writer.nil? || writer == '' $response[:writerPass] = false $response[:writerMessages] << 'Writer name is missing.' + else + require File.join(File.dirname(__FILE__), 'mdtranslator/writers/mdWriters') + ADIWG::Mdtranslator::Writers.handleWriter(intObj) end return $response end