Sasha Yelkhovenka

Results 16 comments of Sasha Yelkhovenka

Here is the way to go: ``` ruby can :b, user_id: user.id ``` Appropriate docs section https://github.com/ryanb/cancan/wiki/Defining-Abilities BTW: I believe you should ask such question on StackOverflow with `cancan` tag....

It would be better if you clean up your code(related models and controller) and post a gist.

I can confirm it in my small-test app where I try to use rails-api. It appear SOMETIMES when I try to get "localhost:3000/tours.json". Rails server restart helps. I will get...

> Why should one write an additional line of code if it works without it? Because sometimes it looks really confusing though your words make sense.

Whether it would work for not-less (static) version?

Still doesn't work for `twitter-bootstrap-rails 3.2.0`, `rails 4.2.1`.

I believe this implementation from `friendly_id` can be used as a basis https://github.com/norman/friendly_id/blob/master/lib/friendly_id/finders.rb https://github.com/norman/friendly_id/blob/master/lib/friendly_id/finder_methods.rb

> ```ruby > c.cooldown_period = lambda do |unit_of_work| > ``` I'm not sure about the `unit_of_work` in the interface. Maybe a queue name would be enough? I'm just thinking about...

> After giving it another thought, I think we can keep it simple :D just queue name. I like the `Sidekiq::JobRecord` idea tho. 😄