FIX: Spoiler logic should live inside of spoiler plugin

This commit removes logic about spoilers because it should live inside
of the discourse-spoiler-alert plugin.

This PR:

https://github.com/discourse/discourse-spoiler-alert/pull/38

also completely removes spoilers from excerpts in order to keep them
from leaking in topic previews and notifications.
This commit is contained in:
Blake Erickson
2020-02-06 07:43:27 -07:00
parent db4ae50928
commit 9207c370d9
2 changed files with 0 additions and 10 deletions

View File

@@ -123,11 +123,6 @@ class ExcerptParser < Nokogiri::XML::SAX::Document
@current_length = 0
@start_excerpt = true
end
# Preserve spoilers
if attributes.include?(["class", "spoiler"])
include_tag("span", attributes)
@in_spoiler = true
end
when "details"
@detail_contents = +"" if @in_details_depth == 0