mirror of
https://github.com/mastodon/mastodon.git
synced 2024-08-20 21:08:15 -07:00
Fix haml-lint Rubocop Style/NumericPredicate
cop (#26040)
This commit is contained in:
parent
586b1c9dca
commit
df05ece265
3 changed files with 5 additions and 5 deletions
|
@ -1,13 +1,13 @@
|
||||||
# This configuration was generated by
|
# This configuration was generated by
|
||||||
# `haml-lint --auto-gen-config`
|
# `haml-lint --auto-gen-config`
|
||||||
# on 2023-07-18 12:15:07 -0400 using Haml-Lint version 0.48.0.
|
# on 2023-07-19 06:41:20 -0400 using Haml-Lint version 0.48.0.
|
||||||
# The point is for the user to remove these configuration records
|
# The point is for the user to remove these configuration records
|
||||||
# one by one as the lints are removed from the code base.
|
# one by one as the lints are removed from the code base.
|
||||||
# Note that changes in the inspected code, or installation of new
|
# Note that changes in the inspected code, or installation of new
|
||||||
# versions of Haml-Lint, may require this file to be generated again.
|
# versions of Haml-Lint, may require this file to be generated again.
|
||||||
|
|
||||||
linters:
|
linters:
|
||||||
# Offense count: 950
|
# Offense count: 951
|
||||||
LineLength:
|
LineLength:
|
||||||
enabled: false
|
enabled: false
|
||||||
|
|
||||||
|
@ -15,7 +15,7 @@ linters:
|
||||||
UnnecessaryStringOutput:
|
UnnecessaryStringOutput:
|
||||||
enabled: false
|
enabled: false
|
||||||
|
|
||||||
# Offense count: 62
|
# Offense count: 59
|
||||||
RuboCop:
|
RuboCop:
|
||||||
enabled: false
|
enabled: false
|
||||||
|
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
.auto-dir
|
.auto-dir
|
||||||
= status_content_format(status)
|
= status_content_format(status)
|
||||||
|
|
||||||
- if status.ordered_media_attachments.size > 0
|
- if status.ordered_media_attachments.size.positive?
|
||||||
%p
|
%p
|
||||||
- status.ordered_media_attachments.each do |a|
|
- status.ordered_media_attachments.each do |a|
|
||||||
- if status.local?
|
- if status.local?
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
- poll.loaded_options.each_with_index do |option, index|
|
- poll.loaded_options.each_with_index do |option, index|
|
||||||
%li
|
%li
|
||||||
- if show_results
|
- if show_results
|
||||||
- percent = total_votes_count > 0 ? 100 * option.votes_count / total_votes_count : 0
|
- percent = total_votes_count.positive? ? 100 * option.votes_count / total_votes_count : 0
|
||||||
%label.poll__option><
|
%label.poll__option><
|
||||||
%span.poll__number><
|
%span.poll__number><
|
||||||
= "#{percent.round}%"
|
= "#{percent.round}%"
|
||||||
|
|
Loading…
Reference in a new issue