Skip to content

A platform for community discussion. Free, open, simple.

FIX: two crashes in the Lithium import script (#42898)

Ary Rabelo1b2d7253e854
diff --git a/script/import_scripts/lithium.rb b/script/import_scripts/lithium.rb
index b44bf6bc704..b29119d6467 100644
--- a/script/import_scripts/lithium.rb
+++ b/script/import_scripts/lithium.rb
@@ -272,7 +272,7 @@ class ImportScripts::Lithium < ImportScripts::Base
nil
end
begin
- file.unlind
+ file.unlink
rescue StandardError
nil
end
@@ -937,8 +937,7 @@ SQL
unless post.raw == new_raw
post.raw = new_raw
post.cooked = post.cook(new_raw)
- cpp = CookedPostProcessor.new(post)
- cpp.link_post_uploads
+ post.link_post_uploads
post.custom_fields["import_post_process"] = true
post.save
end