Commit 21d86f23 authored by Rob Colbert's avatar Rob Colbert

Merge branch 'remote-profile-fix' into 'develop'

Properly load remote profiles

See merge request gab/social/gab-social!27
parents f7e8d8c3 82ba2a7d
......@@ -11,7 +11,12 @@ class Api::V1::AccountByUsernameController < Api::BaseController
end
def set_account
@account = Account.find_local!(params[:username])
user = "#{params[:username]}.#{params[:format]}".split("@")
if user[1]
@account = Account.find_remote!(user[0], user[1])
else
@account = Account.find_local!(user[0])
end
end
def check_account_suspension
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment