diff --git a/Gemfile.lock b/Gemfile.lock index d2b36d2..1abdd09 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -581,7 +581,7 @@ CHECKSUMS rubocop (1.70.0) sha256=96751f8440b36a0ac6e9a8ab596900803118d83d6b83f2037bf8b3d7a5bc440e rubocop-ast (1.37.0) sha256=9513ac88aaf113d04b52912533ffe46475de1362d4aa41141b51b2455827c080 rubocop-factory_bot (2.26.1) sha256=8de13cd4edcee5ca800f255188167ecef8dbfc3d1fae9f15734e9d2e755392aa - rubocop-rails (2.29.0) + rubocop-rails (2.29.0) sha256=35bffd140c80671453aafac0e2d5ab5b3dd65736a3fc8f3936ccca226b89c234 rubocop-rspec (3.3.0) sha256=79e1b281a689044d1516fefbc52e2e6c06cd367c25ebeaf06a7a198e9071cd7d rubocop-rspec_rails (2.30.0) sha256=888112e83f9d7ef7ad2397e9d69a0b9614a4bae24f072c399804a180f80c4c46 ruby-progressbar (1.13.0) sha256=80fc9c47a9b640d6834e0dc7b3c94c9df37f08cb072b7761e4a71e22cff29b33 diff --git a/app/controllers/expenses_controller.rb b/app/controllers/expenses_controller.rb index 093d691..7fd243a 100644 --- a/app/controllers/expenses_controller.rb +++ b/app/controllers/expenses_controller.rb @@ -31,6 +31,6 @@ class ExpensesController < ApplicationController private def expense_params - params.require(:expense).permit(:name, :amount, :pricing_type) + params.expect(expense: %i[name amount pricing_type]) end end diff --git a/app/controllers/guests_controller.rb b/app/controllers/guests_controller.rb index 7aee16d..9a40793 100644 --- a/app/controllers/guests_controller.rb +++ b/app/controllers/guests_controller.rb @@ -32,6 +32,6 @@ class GuestsController < ApplicationController private def guest_params - params.require(:guest).permit(:name, :group_id, :status) + params.expect(guest: %i[name group_id status]) end end