Merge branch 'kb_lts' into kb_development

This commit is contained in:
KMY 2023-09-25 19:39:27 +09:00
commit fc923c4d9b
5 changed files with 72 additions and 1 deletions

View file

@ -265,7 +265,7 @@ class ActivityPub::ProcessAccountService < BaseService
bio = searchability_from_bio
return bio unless bio.nil?
return misskey_software? ? :public : :direct
return misskey_software? ? misskey_searchability_from_indexable : :direct
end
if audience_searchable_by.any? { |uri| ActivityPub::TagManager.instance.public_collection?(uri) }
@ -297,6 +297,12 @@ class ActivityPub::ProcessAccountService < BaseService
searchability
end
def misskey_searchability_from_indexable
return :public if @json['indexable'].nil?
@json['indexable'] ? :public : :limited
end
def instance_info
@instance_info ||= InstanceInfo.find_by(domain: @domain)
end

View file

@ -96,6 +96,7 @@ class PostStatusService < BaseService
end
def load_circle
raise ArgumentError if @options[:visibility] == 'limited' && @options[:circle_id].nil?
return unless @options[:visibility] == 'circle' || (@options[:visibility] == 'limited' && @options[:circle_id].present?)
@circle = @options[:circle_id].present? && Circle.find(@options[:circle_id])