Account.find_remote should be raise ActiveRecord::RecordNotFound (#3476)
This commit is contained in:
		@@ -167,7 +167,7 @@ class Account < ApplicationRecord
 | 
			
		||||
    end
 | 
			
		||||
 | 
			
		||||
    def find_remote!(username, domain)
 | 
			
		||||
      return if username.blank?
 | 
			
		||||
      raise ActiveRecord::RecordNotFound if username.blank?
 | 
			
		||||
      where('lower(accounts.username) = ?', username.downcase).where(domain.nil? ? { domain: nil } : 'lower(accounts.domain) = ?', domain&.downcase).take!
 | 
			
		||||
    end
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user