Skip to content
Snippets Groups Projects
Commit 67530f53 authored by Arnaud Levy's avatar Arnaud Levy
Browse files

complexity

parent e463cc28
No related branches found
No related tags found
No related merge requests found
......@@ -5,11 +5,9 @@ class BlocksMigration
def self.cleanup
Communication::Website::Post.find_each do |post|
next if post.text.blank?
cleanup_item post
end
Communication::Website::Page.find_each do |page|
next if page.text.blank?
cleanup_item page
end
end
......@@ -17,6 +15,7 @@ class BlocksMigration
private
def self.cleanup_item(item)
return if item.text.blank?
puts "#{item} (#{item.id}, #{item.university}, #{item.website})"
return if item.blocks.any?
puts " migrating"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment