fix before login trigger