add password error check