-
-
Save RobinDaugherty/10488139 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def normalized_content_from_content | |
if client | |
options = { | |
blacklisted_elements: client.article_blacklisted_elements, | |
whitelisted_tags: client.article_whitelisted_tags, | |
} | |
else | |
options = nil | |
end | |
ContentNormalization.new(content, options).normalized_content if content | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def normalized_content_from_content | |
options = { | |
blacklisted_elements: client.article_blacklisted_elements, | |
whitelisted_tags: client.article_whitelisted_tags, | |
} | |
ContentNormalization.new(content, options).normalized_content | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment