wetap/wetap-api — pull request #40 by svevang (2014-09-18 15:49:24+00:00)
Title: split permissions behavior across api/application_controller

Fixes up the behavior slightly for https://www.pivotaltracker.com/story/show/66826310

Now instead of just a 4xx and a head, we are redirecting the user and displaying a flash message to indicate there was a permissions problem. The api will still just return a 4xx for CanCan permission errors.