lib/movie.rb in pirate-autonzb-0.4.2 vs lib/movie.rb in pirate-autonzb-0.4.3

- old
+ new

@@ -135,12 +135,17 @@ def set_srt if nfo @srt = nfo.srt elsif matched = @raw_name.match(/\[(.*)\]/) - matched[1].split(',').each { |srt| @srt << srt } + srts = matched[1].split(',') + if srts.empty? + @srt << 'none' + else + srts.each { |srt| @srt << srt } + end else - @srt << 'no nfo' + @srt << 'unknown' end end def set_lang @lang = case @raw_name \ No newline at end of file