Minor changes in comments and names of variables. Also re-factoring of method checkPassword_ids.