Skip to content

Instantly share code, notes, and snippets.

@Olefine
Created August 20, 2013 13:52
Show Gist options
  • Select an option

  • Save Olefine/6281759 to your computer and use it in GitHub Desktop.

Select an option

Save Olefine/6281759 to your computer and use it in GitHub Desktop.
class MessageImageWorker
@queue = :message_image_queue
def self.perform(message_id, image)
message = Message.find(message_id)
message.images << MessageImage.create!(image: image)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment