Adavanced Rails authorizations with pundit

Pundit is a realy simple Ruby Gem, that does nothing more that you could have done yourself. Here is the power ! When updating to Rails 4 in it's early days, you had no compliant authorization solutions. Ryan Bates's Cancan was the…

Airbrake fix

After installing airbrake gem my collection's request Rspec.specs stoped working as expected. I encounterd this error: RuntimeError: can't add a new key into hash during iteration Since Ruby 1.9(.3?) you cant modify Hash within iteration (even if they are ordered). After some hours spent…

Disabling Rails sessions and airbrake gem

After installing airbrake gem and disabling your rails sessions (for example with the session_off gem), you may experiment this kind of errors : undefined method `data' for nil:NilClass This is because airbrake read the session.data property to send them to the server. Since…