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

dry run test

parent 4b6168a9
No related branches found
No related tags found
No related merge requests found
......@@ -9,11 +9,12 @@ class BlocksMigration
puts "#{post} (#{post.id}, #{post.university})"
next if post.blocks.any?
puts " migrating"
block = post.blocks.create university: post.university, template_kind: :chapter
data = block.data
data['text'] = post.text.to_html
block.data = data
block.save
puts post.text.to_html
# block = post.blocks.create university: post.university, template_kind: :chapter
# data = block.data
# data['text'] = post.text.to_html
# block.data = data
# block.save
end
end
end
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