fix a bug in basic login