Skip to content

Instantly share code, notes, and snippets.

@dustin
Forked from therealadam/gist:41457
Created December 30, 2008 00:45
Show Gist options
  • Save dustin/41460 to your computer and use it in GitHub Desktop.
Save dustin/41460 to your computer and use it in GitHub Desktop.
# moved to http://gist.github.com/41462
def whack(objects)
Hash[ *objects.map{|o| [o.send('table_name'), o.send('delete_all')]}.flatten]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment