diff --git a/lib/rubyripper/fileScheme.rb b/lib/rubyripper/fileScheme.rb index afa0004..0a84fe6 100644 --- a/lib/rubyripper/fileScheme.rb +++ b/lib/rubyripper/fileScheme.rb @@ -87,7 +87,7 @@ def getFile(codec, track=nil) # return the toc file of Cdrdao class // TODO this can't be; the dir is not yet created. def getTocFile - File.join(getTempDir(), @filterFiles.filter("#{@md.artist} - #{@md.album}.toc")) + File.join(getTempDir(), @filterFiles.filter("#{giveFileName()}.toc")) end # return the full filename of the log @@ -97,7 +97,7 @@ def getLogFile(codec) # return the full filename of the cuesheet def getCueFile(codec) - File.join(@dir[codec], @filterFiles.filter("#{@md.artist} - #{@md.album} (#{codec}).cue")) + File.join(@dir[codec], @filterFiles.filter("#{giveFileName()}.cue")) end # return the just ripped wave file @@ -235,7 +235,7 @@ def setFileNames end # give the filename for given codec and track - def giveFileName(codec, track=0) + def giveFileName(codec="", track=0) file = File.basename(@fileScheme) # the artist should always refer to the artist that is valid for the track @@ -269,6 +269,7 @@ def fileExtension(codec) when 'wavpack' then '.wv' when 'opus' then '.opus' when 'other' then @otherExtension + when '' then '' end end