mirror of
https://github.com/glitch-soc/mastodon.git
synced 2024-11-16 13:14:17 -05:00
9d55529318
simplify FanOutOnWriteService, add /api/accounts/lookup method
12 lines
251 B
Ruby
12 lines
251 B
Ruby
class Api::Accounts::LookupController < ApplicationController
|
|
def index
|
|
@accounts = Account.where(domain: nil).where(username: lookup_params)
|
|
end
|
|
|
|
private
|
|
|
|
def lookup_params
|
|
(params[:usernames] || '').split(',').map(&:strip)
|
|
end
|
|
end
|