fix logic to prevent redirection loops for user/login in live env

Should fix issue raised by Glenn in #6