[obs-commits] [openSUSE/open-build-service] e288a3: [api] Use in? instead of include? where it makes s...
Branch: refs/heads/master Home: https://github.com/openSUSE/open-build-service Commit: e288a3d47b9152c3725b33c87913bbe8ed697a92 https://github.com/openSUSE/open-build-service/commit/e288a3d47b9152c3725b33... Author: Björn Geuken <bgeuken@suse.de> Date: 2017-02-16 (Thu, 16 Feb 2017) Changed paths: M src/api/app/controllers/request_controller.rb M src/api/app/controllers/source_controller.rb M src/api/app/controllers/webui/request_controller.rb M src/api/app/helpers/webui/buildresult_helper.rb M src/api/app/helpers/webui/package_helper.rb M src/api/app/helpers/webui/webui_helper.rb M src/api/app/mixins/webui/load_buildresults.rb M src/api/app/models/bs_request.rb M src/api/app/models/bs_request_action.rb M src/api/app/models/bs_request_permission_check.rb M src/api/app/models/buildresult.rb M src/api/app/models/configuration.rb M src/api/app/models/package_build_status.rb M src/api/app/models/project.rb M src/api/app/models/user.rb M src/api/app/views/webui/request/show.html.erb M src/api/lib/xpath_engine.rb Log Message: ----------- [api] Use in? instead of include? where it makes sense eg. my_var.in?(["a", "b", "c"]) vs ["a", "b", "c"].include?(my_var) The latter versions puts the focus on ["a", "b", "c"], while we actually care about the content of my_var. http://api.rubyonrails.org/classes/Object.html#method-i-in-3F Commit: b11e8d774a279d63914f9608271a1ffc3b6e9f2a https://github.com/openSUSE/open-build-service/commit/b11e8d774a279d63914f96... Author: Björn Geuken <bgeuken@suse.de> Date: 2017-02-16 (Thu, 16 Feb 2017) Changed paths: M src/api/app/controllers/request_controller.rb M src/api/app/controllers/source_controller.rb M src/api/app/controllers/webui/request_controller.rb M src/api/app/helpers/webui/buildresult_helper.rb M src/api/app/helpers/webui/package_helper.rb M src/api/app/helpers/webui/webui_helper.rb M src/api/app/mixins/webui/load_buildresults.rb M src/api/app/models/bs_request.rb M src/api/app/models/bs_request_action.rb M src/api/app/models/bs_request_permission_check.rb M src/api/app/models/buildresult.rb M src/api/app/models/configuration.rb M src/api/app/models/package_build_status.rb M src/api/app/models/project.rb M src/api/app/models/user.rb M src/api/app/views/webui/request/show.html.erb M src/api/lib/xpath_engine.rb Log Message: ----------- Merge pull request #2657 from bgeuken/in_include [api] Use in? instead of include? where it makes sense Compare: https://github.com/openSUSE/open-build-service/compare/859230211ab0...b11e8d...
participants (1)
-
Björn Geuken