1
0
mirror of https://github.com/meineerde/redmine.git synced 2026-02-01 03:57:15 +00:00

Update .rubocop_todo and fix Style/AndOr offense (#29914, #32938).

git-svn-id: http://svn.redmine.org/redmine/trunk@21253 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Marius Balteanu 2021-10-20 22:21:19 +00:00
parent 7125fd70ce
commit 0dd9fbb806
2 changed files with 4 additions and 5 deletions

View File

@ -1070,7 +1070,6 @@ Style/AndOr:
- 'lib/redmine/scm/adapters/filesystem_adapter.rb'
- 'lib/redmine/scm/adapters/git_adapter.rb'
- 'lib/redmine/scm/adapters/subversion_adapter.rb'
- 'lib/redmine/wiki_formatting.rb'
- 'lib/redmine/wiki_formatting/textile/redcloth3.rb'
# Cop supports --auto-correct.
@ -1399,7 +1398,7 @@ Style/MultilineIfModifier:
- 'app/models/time_entry_query.rb'
- 'app/views/common/feed.atom.builder'
- 'lib/redmine/helpers/gantt.rb'
- 'lib/redmine/wiki_formatting.rb'
- 'lib/redmine/wiki_formatting/links_helper.rb'
- 'lib/redmine/wiki_formatting/textile/redcloth3.rb'
# Cop supports --auto-correct.
@ -1615,7 +1614,7 @@ Style/RedundantInterpolation:
- 'app/views/journals/index.builder'
- 'lib/redmine/helpers/time_report.rb'
- 'lib/redmine/scm/adapters/subversion_adapter.rb'
- 'lib/redmine/wiki_formatting.rb'
- 'lib/redmine/wiki_formatting/links_helper.rb'
- 'test/functional/versions_controller_test.rb'
- 'test/functional/watchers_controller_test.rb'
@ -1791,7 +1790,7 @@ Style/StringLiteralsInInterpolation:
- 'app/models/issue_query.rb'
- 'config/environment.rb'
- 'lib/redmine/scm/adapters/cvs_adapter.rb'
- 'lib/redmine/wiki_formatting.rb'
- 'lib/redmine/wiki_formatting/links_helper.rb'
- 'lib/redmine/wiki_formatting/textile/redcloth3.rb'
- 'test/unit/member_test.rb'

View File

@ -52,7 +52,7 @@ module Redmine
else
# Idea below : an URL with unbalanced parenthesis and
# ending by ')' is put into external parenthesis
if url[-1] == ")" and ((url.count("(") - url.count(")")) < 0)
if url[-1] == ")" && ((url.count("(") - url.count(")")) < 0)
url = url[0..-2] # discard closing parenthesis from url
post = ")" + post # add closing parenthesis to post
end