]> cat aescling's git repositories - mastodon.git/commitdiff
Remove extra spaces from search API queries and public account headers (fixes #7129...
authorThibG <thib@sitedethib.com>
Mon, 16 Apr 2018 15:19:04 +0000 (17:19 +0200)
committerEugen Rochko <eugen@zeonfederated.com>
Mon, 16 Apr 2018 15:19:04 +0000 (17:19 +0200)
app/services/search_service.rb
app/views/accounts/_header.html.haml

index 00a8b3dd77d90fb55e72d6704f634b32469eb3be..5bb395942da0bec28894e68d02db0600b8c84beb 100644 (file)
@@ -4,7 +4,7 @@ class SearchService < BaseService
   attr_accessor :query, :account, :limit, :resolve
 
   def call(query, limit, resolve = false, account = nil)
-    @query   = query
+    @query   = query.strip
     @account = account
     @limit   = limit
     @resolve = resolve
index 0d3a0d08d87388da12e6b86b0fb4d840a12a6aa2..f246f53262d7d24ced275ebbecefcadef96802b1 100644 (file)
@@ -6,8 +6,8 @@
   .card__bio
     %h1.name
       %span.p-name.emojify= display_name(account)
-      %small
-        %span @#{account.local_username_and_domain}
+      %small<
+        %span>< @#{account.local_username_and_domain}
         = fa_icon('lock') if account.locked?
 
     - if Setting.show_staff_badge