Skip to content

Instantly share code, notes, and snippets.

@nz
Created October 30, 2009 16:41
Show Gist options
  • Save nz/222510 to your computer and use it in GitHub Desktop.
Save nz/222510 to your computer and use it in GitHub Desktop.
class Foo
has_attached_file :image
def image=(image)
if super(image)
do_stuff_with!(@temp_uploaded_file)
end
end
def do_stuff_with!(file)
# extract metadata, add to metadata, post-process, whateva'
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment