change password frontend logic