Skip to content

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

FIX: do not strip nil string

Arpit Jalan5ff84be8ccc1
diff --git a/plugins/poll/plugin.rb b/plugins/poll/plugin.rb
index 6a4ea272d89..2c35a881754 100644
--- a/plugins/poll/plugin.rb
+++ b/plugins/poll/plugin.rb
@@ -268,7 +268,7 @@ after_initialize do
PollOption.create!(
poll: created_poll,
digest: option["id"].presence,
- html: option["html"].presence.strip
+ html: option["html"].presence&.strip
)
end
end