def save
      self.queue.each do |style, file|
        path = self.path(style)
        self.storage.save(file, path) if file and path
      end
      self.purge.each do |path|
        self.storage.destroy(path)
      end
      @purge = []
      @queue = {}
    end
def save
      self.queue.each do |style, file|
        path = self.path(style)
        self.storage.save(file, path) if file and path
      end
      self.purge.each do |path|
        self.storage.destroy(path)
      end
      @purge = []
      @queue = {}
    end
Save an attachment.

 Usage:

   @object.avatar.save