@@ -114,7 +114,7 @@ def self.weekly_tallies
114
114
115
115
# finds the brightest row of the image and uses that as its sample row
116
116
def find_brightest_row
117
- photo . copy_to_local_file ( :original )
117
+ photo . copy_to_local_file ( :original , local_photo_path )
118
118
image = Magick ::ImageList . new ( local_photo_path )
119
119
brightest_row = 0
120
120
brightest = 0
@@ -141,7 +141,7 @@ def find_brightest_row
141
141
def extract_data
142
142
pixels = [ ]
143
143
144
- photo . copy_to_local_file ( :original )
144
+ photo . copy_to_local_file ( :original , local_photo_path )
145
145
image = Magick ::ImageList . new ( local_photo_path )
146
146
# saved sample_row may be greater than image height, so temporarily compensate,
147
147
# but preserve sample_row in case we rotate back or something
@@ -280,7 +280,7 @@ def clone_calibration(clone_id)
280
280
281
281
# rotate clockwise
282
282
def rotate
283
- photo . copy_to_local_file ( :original )
283
+ photo . copy_to_local_file ( :original , local_photo_path )
284
284
image = Magick ::ImageList . new ( local_photo_path )
285
285
image . rotate! ( -90 )
286
286
image . write ( 'public' + photo . url )
@@ -289,7 +289,7 @@ def rotate
289
289
290
290
# horizontally flips image to match reversed spectrum, toggles 'reversed' flag
291
291
def reverse
292
- photo . copy_to_local_file ( :original )
292
+ photo . copy_to_local_file ( :original , local_photo_path )
293
293
image = Magick ::ImageList . new ( local_photo_path )
294
294
image . flop!
295
295
image . write ( 'public' + photo . url )
0 commit comments