fix redirect on login. closes #182.

thanks @damon18 for pointing out the issue.