login_require fix