Branch: refs/heads/depfu/update/srcapi/rubocop-0.88.0
Home: https://github.com/openSUSE/open-build-service
Commit: 9533a141b04971257e3bbb33fedfe115949ed7fb
https://github.com/openSUSE/open-build-service/commit/9533a141b04971257e3bbb...
Author: Dani Donisa
Date: 2020-07-17 (Fri, 17 Jul 2020)
Changed paths:
M src/api/app/controllers/group_controller.rb
M src/api/app/controllers/public_controller.rb
M src/api/app/controllers/source_project_controller.rb
M src/api/app/controllers/webui/kiwi/images_controller.rb
M src/api/app/controllers/webui/package_controller.rb
M src/api/app/controllers/webui/repositories_controller.rb
M src/api/app/controllers/webui/sitemaps_controller.rb
M src/api/app/controllers/webui/webui_controller.rb
M src/api/app/lib/suse/permission.rb
M src/api/app/models/bs_request.rb
M src/api/app/models/event_subscription.rb
M src/api/app/models/event_subscription/find_for_event.rb
M src/api/app/models/project.rb
M src/api/app/models/review.rb
M src/api/app/views/statistics/highest_rated.xml.builder
M src/api/config/application.rb
M src/api/db/data/20170831143534_convert_notifications_event_payload_to_json.rb
M src/api/lib/tasks/statistics/github/code_frequency.rake
M src/api/lib/tasks/statistics/github/commit_activity.rake
M src/api/lib/xpath_engine.rb
M src/api/spec/controllers/webui/users_controller_spec.rb
M src/api/spec/db/data/project_log_entry_user_name_spec.rb
M src/api/spec/factories/project.rb
M src/api/spec/factories/staging_workflow.rb
M src/api/spec/models/bs_request_spec.rb
M src/api/spec/models/user_spec.rb
M src/api/spec/support/database_cleaner.rb
M src/api/test/functional/published_controller_test.rb
M src/api/test/unit/schema_test.rb
Log Message:
-----------
Auto-correct rubocop issues after major version update
After upgrading the rubocop gem version from 0.87.1 to 0.88.0
the following new cop got introduced and autocorrected:
* Style/ArrayCoercion
* Style/CaseLikeIf
* Style/HashAsLastArrayItem
* Style/RedundantFileExtensionInRequire
Commit: 2968e173e3f7abb6d1ad9bfbe8704275a33f3bc3
https://github.com/openSUSE/open-build-service/commit/2968e173e3f7abb6d1ad9b...
Author: Dani Donisa
Date: 2020-07-17 (Fri, 17 Jul 2020)
Changed paths:
M src/api/app/controllers/webui/webui_controller.rb
Log Message:
-----------
Transform case into hash lookup
This fixes the `Style/HashLikeCase` cop which got introduced
after the rubocop gem update from version 0.87.1 to 0.88.0
Commit: 33ab5c82a4a5758cdc4ce85a3ce9b81d4fd6a67d
https://github.com/openSUSE/open-build-service/commit/33ab5c82a4a5758cdc4ce8...
Author: Dani Donisa
Date: 2020-07-17 (Fri, 17 Jul 2020)
Changed paths:
M src/api/spec/factories/project.rb
Log Message:
-----------
Revert rubocop autocorrection for Style/ArrayCoercion
The autocorrection for this part of the code introduced
changes in the behaviour of it. Therefore we ignore
the cop here, and keep the code as it is.
Commit: 1de2cc9c22bd9d0c5441672a2116ab6a66bb48c7
https://github.com/openSUSE/open-build-service/commit/1de2cc9c22bd9d0c544167...
Author: Dani Donisa
Date: 2020-07-17 (Fri, 17 Jul 2020)
Changed paths:
M src/api/app/helpers/webui/buildresult_helper.rb
M src/api/app/views/webui/package/_rpmlint_log.html.haml
Log Message:
-----------
Extract helper and replace if with case
Address Style/CaseLikeIf cop and move logic from view to a
helper method (addressing a FIXME comment).
Commit: 48b8cc45c6bfa055b55cd8c5b4925f15870e2988
https://github.com/openSUSE/open-build-service/commit/48b8cc45c6bfa055b55cd8...
Author: Lukas Krause
Date: 2020-07-17 (Fri, 17 Jul 2020)
Changed paths:
M src/api/app/controllers/webui/repositories_controller.rb
Log Message:
-----------
Fix regex match group handling after moving to case statements
The rubocop autocorrect for Style/CaseLikeIf does not take into
account the match operator for regex, which in this case
returns the matched data when using it with and if/elsif statement.
After just moving this to an case statement, the data is not returned
anymore.
This could be fixed by using the `$LAST_MATCH_INFO` which
contains the whole `MatchData` object of the latest regex matching group.
Compare: https://github.com/openSUSE/open-build-service/compare/876d92c0188d...48b8cc...