diff options
-rw-r--r-- | app/services/post_status_service.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/services/post_status_service.rb b/app/services/post_status_service.rb index e34430f09..8fbf9d9b6 100644 --- a/app/services/post_status_service.rb +++ b/app/services/post_status_service.rb @@ -105,8 +105,8 @@ class PostStatusService < BaseService # move tags out of body so we can format them later def extract_tags chunks = [] - @text.split(/^((?:#[\w:._·\-]*\s*)+)/).each do |chunk| - if chunk.start_with?('#') + @text.split(/^((?:#[\w:._·\-]+\s*)+)/).each do |chunk| + if chunk.start_with?('#') && !chunk.start_with?('#!') @tags |= chunk[1..-1].split(/\s+/) else chunks << chunk |