-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore(deps-dev): update rubocop to ~> 1.58.0 in multiple gems #756
chore(deps-dev): update rubocop to ~> 1.58.0 in multiple gems #756
Conversation
Redundant safe navigation with default literal detected. prefix = endpoint.routes.first.options[:prefix]&.to_s || '' ^^^^^^^^^^^^ OK. We can stop at safely navigating the string coersion without supplying a default because paths.reject{} below filters nils.
Redundant return detected. return "HTTP #{request_method} #{request_path} miniswan" ^^^^^^ Sure.
Don't use parentheses around a logical expression. (!gem_version.nil? && gem_version >= MINIMUM_VERSION) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ OK.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
version = endpoint.routes.first.options[:version] || '' | ||
prefix = endpoint.routes.first.options[:prefix]&.to_s || '' | ||
version = endpoint.routes.first.options[:version]&.to_s | ||
prefix = endpoint.routes.first.options[:prefix]&.to_s |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can stop at safely navigating the string coercion without supplying a default because parts.reject{}
below filters nil
s.
@@ -22,7 +22,7 @@ class Instrumentation < OpenTelemetry::Instrumentation::Base | |||
end | |||
|
|||
compatible do | |||
(!gem_version.nil? && gem_version >= MINIMUM_VERSION) | |||
!gem_version.nil? && gem_version >= MINIMUM_VERSION |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
appease Rubocop: Style/RedundantParentheses
Don't use parentheses around a logical expression.
(!gem_version.nil? && gem_version >= MINIMUM_VERSION)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
OK.
@@ -128,7 +128,7 @@ | |||
let(:span_name_formatter) do | |||
# demonstrate simple addition of path and string to span name: | |||
lambda { |request_method, request_path| | |||
return "HTTP #{request_method} #{request_path} miniswan" | |||
"HTTP #{request_method} #{request_path} miniswan" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
appease Rubocop: Style/RedundantReturn
Redundant return detected.
return "HTTP #{request_method} #{request_path} miniswan"
^^^^^^
Sure.
Update gemspecs
When dependabot is piecemealing a monorepo of gems (#748, #749, #750. #751, #752. #753, #754), go Old School:
Rubocop Appeasements
Lint/RedundantSafeNavigation
OK. We can stop at safely navigating the string coercion without supplying a default because
paths.reject{}
below filtersnil
s.Style/RedundantReturn
Sure.
Style/RedundantParentheses
OK.