Class | Paperclip::Tempfile
In: | vendor/plugins/paperclip/lib/paperclip/processor.rb
Parent: | ::Tempfile

Due to how ImageMagick handles its image format conversion and how Tempfile handles its naming scheme, it is necessary to override how Tempfile makes its names so as to allow for file extensions. Idea taken from the comments on this blog post: marsorange.com/archives/of-mogrify-ruby-tempfile-dynamic-class-definitions

### Methods

make_tmpname

### Public Instance methods

make_tmpname(basename, n)

Replaces Tempfile‘s `make_tmpname` with one that honors file extensions.

[Source]

        # File vendor/plugins/paperclip/lib/paperclip/processor.rb, line 43
    43:     def make_tmpname(basename, n)
    44:       extension = File.extname(basename)
    45:       sprintf("%s,%d,%d%s", File.basename(basename, extension), $$, n, extension)
    46:     end

[Validate]