class DK::Post
Public Instance Methods
has_info?()
click to toggle source
Post
has a summary or tags?
# File lib/autofixer/patches/DK_Post.rb, line 4 def has_info? has_summary? || !tags.empty? end
has_summary?()
click to toggle source
# File lib/autofixer/patches/DK_Post.rb, line 21 def has_summary? summary.strip.empty? end
has_trail?()
click to toggle source
Do we know where it was reblogged from?
# File lib/autofixer/patches/DK_Post.rb, line 9 def has_trail? !trail.empty? end
processed?(skip: false, prefix: '')
click to toggle source
Post
already has prefix?
# File lib/autofixer/patches/DK_Post.rb, line 14 def processed?(skip: false, prefix: '') return false if skip return false if prefix.empty? l_comment = Sanitize.fragment(comment).strip l_comment.start_with?(prefix) || summary.strip.start_with?(prefix) end