Updated login for redirect