Using boilerplate with angular i noticed that angular sets the csrf token in ajax post requests as a request header and not in the request body.  This change caters to that
Merge pull request #296 from ybashir/master

To make this code work with angularjs ajax post requests