added truncating blog_categories_blog_posts to reset_blog task
This commit is contained in:
parent
2dbf9d31b2
commit
49a49bbab8
|
@ -5,7 +5,7 @@ namespace :wordpress do
|
|||
task :reset_blog do
|
||||
Rake::Task["environment"].invoke
|
||||
|
||||
%w(taggings tags blog_comments blog_categories blog_posts).each do |table_name|
|
||||
%w(taggings tags blog_comments blog_categories blog_categories_blog_posts blog_posts).each do |table_name|
|
||||
p "Truncating #{table_name} ..."
|
||||
ActiveRecord::Base.connection.execute "DELETE FROM #{table_name}"
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue
Block a user