Skip to content

Instantly share code, notes, and snippets.

@re5et
Created March 9, 2011 23:42
Show Gist options
  • Save re5et/863259 to your computer and use it in GitHub Desktop.
Save re5et/863259 to your computer and use it in GitHub Desktop.
change_source_images_collection_name.rb
class ChangeSourceImagesCollectionName < Mongoid::Migration
def self.up
collection = connection.collection('source_images')
collection.rename('imagickals')
end
def self.down
collection = connection.collection('imagickals')
collection.rename('source_images')
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment