Skip to content

Commit

Permalink
Make the examples match
Browse files Browse the repository at this point in the history
  • Loading branch information
saturnflyer committed Apr 11, 2024
1 parent b84520b commit 26548e3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ class MyPolicy < ApplicationPolicy
end

# Return the params for the action but require a special key
def params_for_create(params)
params_for(@record, params, :create).tap do |params|
def params_for_update(params)
params_for(@record, params, :update).tap do |params|
params.require(:special_key)
end
end
Expand Down

0 comments on commit 26548e3

Please sign in to comment.