Skip to content
Browse files

Added migration to remove pallet from db.

  • Loading branch information...
1 parent a293ca4 commit a6d4aa009240ed5137f751eacdc6cb66dcf02df8 @zk committed
Showing with 20 additions and 1 deletion.
  1. +19 −0 db/migrate/20110926024801_remove_pallet.rb
  2. +1 −1 db/schema.rb
View
19 db/migrate/20110926024801_remove_pallet.rb
@@ -0,0 +1,19 @@
+class RemovePallet < ActiveRecord::Migration
+ def self.up
+ lib = Library.find_by_name("pallet")
+
+ return if not lib
+
+ lib.namespaces.each do |ns|
+ ns.functions.each do |f|
+ f.delete
+ end
+ ns.delete
+ end
+ lib.delete
+
+ end
+
+ def self.down
+ end
+end
View
2 db/schema.rb
@@ -9,7 +9,7 @@
#
# It's strongly recommended to check this file into your version control system.
-ActiveRecord::Schema.define(:version => 20110926021317) do
+ActiveRecord::Schema.define(:version => 20110926024801) do
create_table "comments", :force => true do |t|
t.integer "commentable_id", :default => 0

0 comments on commit a6d4aa0

Please sign in to comment.
Something went wrong with that request. Please try again.