diff --git a/app/models/spectrum.rb b/app/models/spectrum.rb index adf9fa36..0f20b42f 100755 --- a/app/models/spectrum.rb +++ b/app/models/spectrum.rb @@ -283,7 +283,7 @@ def rotate photo.copy_to_local_file(:original,local_photo_path) image = Magick::ImageList.new(local_photo_path) image.rotate!(-90) - image.write('public' + photo.url) + image.write(local_photo_path) photo.reprocess! end @@ -292,7 +292,7 @@ def reverse photo.copy_to_local_file(:original,local_photo_path) image = Magick::ImageList.new(local_photo_path) image.flop! - image.write('public' + photo.url) + image.write(local_photo_path) self.reversed = !reversed photo.reprocess! end @@ -639,4 +639,4 @@ def local_photo_path "/tmp/#{self.id}" end -end \ No newline at end of file +end