Fixed deprecation warning.

The new connect version breaks my code, since the behavior of the csrf() function was changed.
Merge pull request #884 from lippling/patch-1

Fixed deprecation warning.