Do not implement specific case fixes.

This commit is contained in:
2018-02-21 11:54:41 -03:00
parent dc487ade62
commit a7fa647f78
2 changed files with 1 additions and 2 deletions
-1
View File
@@ -62,7 +62,6 @@ module Dunlop::SourceFileModel
def pre_process_working_file(target_path = working_file.path)
Dunlop::FileSed.fix_line_endings(target_path)
Dunlop::FileSed.in_place(target_path, %Q{s/"//g})
end
def load_source_records
+1 -1
View File
@@ -3,7 +3,7 @@ module Dunlop::FileZip
def self.unzip(zipped_filename, unzipped_filename)
case self.mime_type(zipped_filename)
when "application/zip"
if zipped_filename.end_with?('.xlsx') # .xlsx IS a zipfile
if zipped_filename.to_s.end_with?('.xlsx') # .xlsx IS a zipfile # .to_s is because it can be a Pathname
%x[ cp #{zipped_filename} #{unzipped_filename} ]
else
%x[ unzip -p #{zipped_filename} > #{unzipped_filename} ]