Update rubocop
to version 1.75.0 (#34283)
This commit is contained in:
parent
e9fe01e2a6
commit
0e3ff680d3
6 changed files with 15 additions and 13 deletions
|
@ -1,6 +1,6 @@
|
|||
# This configuration was generated by
|
||||
# `rubocop --auto-gen-config --auto-gen-only-exclude --no-offense-counts --no-auto-gen-timestamp`
|
||||
# using RuboCop version 1.73.2.
|
||||
# using RuboCop version 1.75.0.
|
||||
# The point is for the user to remove these configuration records
|
||||
# one by one as the offenses are removed from the code base.
|
||||
# Note that changes in the inspected code, or installation of new
|
||||
|
@ -45,7 +45,7 @@ Style/FetchEnvVar:
|
|||
- 'lib/tasks/repo.rake'
|
||||
|
||||
# This cop supports safe autocorrection (--autocorrect).
|
||||
# Configuration parameters: EnforcedStyle, MaxUnannotatedPlaceholdersAllowed, AllowedMethods, AllowedPatterns.
|
||||
# Configuration parameters: EnforcedStyle, MaxUnannotatedPlaceholdersAllowed, Mode, AllowedMethods, AllowedPatterns.
|
||||
# SupportedStyles: annotated, template, unannotated
|
||||
# AllowedMethods: redirect
|
||||
Style/FormatStringToken:
|
||||
|
@ -73,7 +73,6 @@ Style/MapToHash:
|
|||
# AllowedMethods: respond_to_missing?
|
||||
Style/OptionalBooleanParameter:
|
||||
Exclude:
|
||||
- 'app/helpers/json_ld_helper.rb'
|
||||
- 'app/lib/admin/system_check/message.rb'
|
||||
- 'app/lib/request.rb'
|
||||
- 'app/lib/webfinger.rb'
|
||||
|
|
12
Gemfile.lock
12
Gemfile.lock
|
@ -580,7 +580,7 @@ GEM
|
|||
ox (2.14.22)
|
||||
bigdecimal (>= 3.0)
|
||||
parallel (1.26.3)
|
||||
parser (3.3.7.2)
|
||||
parser (3.3.7.3)
|
||||
ast (~> 2.4.1)
|
||||
racc
|
||||
parslet (2.0.0)
|
||||
|
@ -600,6 +600,7 @@ GEM
|
|||
net-smtp
|
||||
premailer (~> 1.7, >= 1.7.9)
|
||||
prettyprint (0.2.0)
|
||||
prism (1.4.0)
|
||||
prometheus_exporter (2.2.0)
|
||||
webrick
|
||||
propshaft (1.1.0)
|
||||
|
@ -733,7 +734,7 @@ GEM
|
|||
rspec-mocks (~> 3.0)
|
||||
sidekiq (>= 5, < 9)
|
||||
rspec-support (3.13.2)
|
||||
rubocop (1.74.0)
|
||||
rubocop (1.75.0)
|
||||
json (~> 2.3)
|
||||
language_server-protocol (~> 3.17.0.2)
|
||||
lint_roller (~> 1.1.0)
|
||||
|
@ -741,11 +742,12 @@ GEM
|
|||
parser (>= 3.3.0.2)
|
||||
rainbow (>= 2.2.2, < 4.0)
|
||||
regexp_parser (>= 2.9.3, < 3.0)
|
||||
rubocop-ast (>= 1.38.0, < 2.0)
|
||||
rubocop-ast (>= 1.43.0, < 2.0)
|
||||
ruby-progressbar (~> 1.7)
|
||||
unicode-display_width (>= 2.4.0, < 4.0)
|
||||
rubocop-ast (1.38.1)
|
||||
parser (>= 3.3.1.0)
|
||||
rubocop-ast (1.43.0)
|
||||
parser (>= 3.3.7.2)
|
||||
prism (~> 1.4)
|
||||
rubocop-capybara (2.22.1)
|
||||
lint_roller (~> 1.1)
|
||||
rubocop (~> 1.72, >= 1.72.1)
|
||||
|
|
|
@ -260,7 +260,7 @@ class Request
|
|||
outer_e = nil
|
||||
port = args.first
|
||||
|
||||
addresses = [] # rubocop:disable Lint/UselessAssignment -- TODO: https://github.com/rubocop/rubocop/issues/13395
|
||||
addresses = []
|
||||
begin
|
||||
addresses = [IPAddr.new(host)]
|
||||
rescue IPAddr::InvalidAddressError
|
||||
|
|
|
@ -33,7 +33,8 @@ class Trends::Links < Trends::Base
|
|||
def register(status, at_time = Time.now.utc)
|
||||
original_status = status.proper
|
||||
|
||||
return unless (original_status.public_visibility? && status.public_visibility?) &&
|
||||
return unless original_status.public_visibility? &&
|
||||
status.public_visibility? &&
|
||||
!(original_status.account.silenced? || status.account.silenced?) &&
|
||||
!(original_status.spoiler_text? || original_status.sensitive?)
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ module Payloadable
|
|||
payload = ActiveModelSerializers::SerializableResource.new(record, options.merge(serializer: serializer, adapter: ActivityPub::Adapter)).as_json
|
||||
object = record.respond_to?(:virtual_object) ? record.virtual_object : record
|
||||
|
||||
if (object.respond_to?(:sign?) && object.sign?) && signer && (always_sign || signing_enabled?)
|
||||
if object.respond_to?(:sign?) && object.sign? && signer && (always_sign || signing_enabled?)
|
||||
ActivityPub::LinkedDataSignature.new(payload).sign!(signer, sign_with: sign_with)
|
||||
else
|
||||
payload
|
||||
|
|
|
@ -8,7 +8,7 @@ class PollExpirationNotifyWorker
|
|||
def perform(poll_id)
|
||||
@poll = Poll.find(poll_id)
|
||||
|
||||
return if does_not_expire?
|
||||
return if missing_expiration?
|
||||
requeue! && return if not_due_yet?
|
||||
|
||||
notify_remote_voters_and_owner! if @poll.local?
|
||||
|
@ -24,7 +24,7 @@ class PollExpirationNotifyWorker
|
|||
|
||||
private
|
||||
|
||||
def does_not_expire?
|
||||
def missing_expiration?
|
||||
@poll.expires_at.nil?
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue