stalniy / rails-cancan-api-example

Simple Rails 5 REST API with cancan
12 stars 7 forks source link

update code for casl 4.x #2

Closed twnaing closed 4 years ago

twnaing commented 4 years ago

related issue

I think the sample should be updated with the followings for casl 4.x (at models/ability.rb:26)

  1. action instead of actions (not breaking, but action is now recommended)
  2. subjectName insetad of subject in (breaking change) a. blog post b. example
stalniy commented 4 years ago

I updated action field but don't know why you decided that subject needs to be replaced with subjectName