Fixes login redirect with failed password.

Fixes #513.
Merge pull request #516 from ahinz/fix/513/login-redirect-workflow

Fixes login redirect with failed password.