From d339d2bbb4aab43d810064bc12bdd0edaebd7263 Mon Sep 17 00:00:00 2001 From: multiple creatures Date: Sat, 27 Apr 2019 14:17:25 -0500 Subject: Make sure signatures start a new paragraph and that existing signatures are detected correctly. --- app/lib/bangtags.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'app/lib') diff --git a/app/lib/bangtags.rb b/app/lib/bangtags.rb index 82049f56b..6f2f03d30 100644 --- a/app/lib/bangtags.rb +++ b/app/lib/bangtags.rb @@ -429,9 +429,9 @@ class Bangtags name = @vars['_they:are'] next if name.blank? description = @vars["_they:are:#{name}"] - next if description.blank? || @chunks.last.starts_with?('—') + next if description.blank? || @chunks.last(5).any? {|c| c.include?('—')} status.local_only = true if Status::LOCAL_ONLY_TOKENS.match?(@chunks.last) - @chunks << "\n\u200c\n[right]— #{description}\u200c[/right]" + @chunks << "\n\n[right]— #{description}\u200c[/right]" when 'media' media_idx = post_cmd[1] media_cmd = post_cmd[2] -- cgit