lib/deliver/download_screenshots.rb in deliver-1.6.6 vs lib/deliver/download_screenshots.rb in deliver-1.7.0

- old
+ new

@@ -18,10 +18,17 @@ original_file_extension = File.basename(screenshot.original_file_name) file_name += "." + original_file_extension Helper.log.info "Downloading existing screenshot '#{file_name}'" - containing_folder = File.join(folder_path, "screenshots", screenshot.language) + # If the screen shot is for an appleTV we need to store it in a way that we'll know it's an appleTV + # screen shot later as the screen size is the same as an iPhone 6 Plus in landscape. + if screenshot.device_type == "appleTV" + containing_folder = File.join(folder_path, "screenshots", "appleTV", screenshot.language) + else + containing_folder = File.join(folder_path, "screenshots", screenshot.language) + end + begin FileUtils.mkdir_p(containing_folder) rescue # if it's already there end