Merge branch 'main' into glitch-soc/merge-upstream

This commit is contained in:
Claire
2022-08-21 14:39:25 +02:00
9 changed files with 79 additions and 99 deletions

View File

@@ -234,8 +234,6 @@ export default function notifications(state = initialState, action) {
case FOLLOW_REQUEST_AUTHORIZE_SUCCESS:
case FOLLOW_REQUEST_REJECT_SUCCESS:
return filterNotifications(state, [action.id], 'follow_request');
case ACCOUNT_MUTE_SUCCESS:
return action.relationship.muting_notifications ? filterNotifications(state, [action.relationship.id]) : state;
case NOTIFICATIONS_CLEAR:
return state.set('items', ImmutableList()).set('pendingItems', ImmutableList()).set('hasMore', false);
case TIMELINE_DELETE:

View File

@@ -84,6 +84,6 @@ class Importer::StatusesIndexImporter < Importer::BaseImporter
end
def local_statuses_scope
Status.local.select('id, coalesce(reblog_of_id, id) as status_id')
Status.local.select('"statuses"."id", COALESCE("statuses"."reblog_of_id", "statuses"."id") AS status_id')
end
end

View File

@@ -105,11 +105,13 @@ class ActivityPub::ProcessAccountService < BaseService
def set_fetchable_attributes!
begin
@account.avatar_remote_url = image_url('icon') || '' unless skip_download?
@account.avatar = nil if @account.avatar_remote_url.blank?
rescue Mastodon::UnexpectedResponseError, HTTP::TimeoutError, HTTP::ConnectionError, OpenSSL::SSL::SSLError
RedownloadAvatarWorker.perform_in(rand(30..600).seconds, @account.id)
end
begin
@account.header_remote_url = image_url('image') || '' unless skip_download?
@account.header = nil if @account.header_remote_url.blank?
rescue Mastodon::UnexpectedResponseError, HTTP::TimeoutError, HTTP::ConnectionError, OpenSSL::SSL::SSLError
RedownloadHeaderWorker.perform_in(rand(30..600).seconds, @account.id)
end

View File

@@ -18,7 +18,7 @@
.filter-subset.filter-subset--with-select
%strong= t 'generic.order_by'
.input.select
= select_tag :order, options_for_select([[t('relationships.most_recent'), nil], [t('relationships.last_active'), 'active']], params[:order])
= select_tag :order, options_for_select([[t('relationships.most_recent'), 'recent'], [t('relationships.last_active'), 'active']], params[:order])
.fields-group
- %i(username by_domain display_name email ip).each do |key|