fixed logical error with google and facebook login