Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public JSONObject passwordReset(String email){
- Node location_of_user_like=null;
- JSONObject json = new JSONObject();
- Node user = null;
- JDBCMySql jdbc=new JDBCMySql();
- try {
- user=indexToNode("id", email);
- if(user==null){
- json.put("status", "fail");
- json.put("desc", "You have not an acccount in ceylon eye.");
- return json;
- }
- String password=user.getProperty("password").toString();
- String text="Reset Password\n\n username:-"+email+"\npassword:-"+password+"";
- AdminOperations admin=new AdminOperations();
- admin.sendMessage(email, "Reset Password", text);
- json.put("status", "sucesses");
- json.put("desc", "password reset sucessfully.");
- }
- catch(Exception e){}
- return json;
- }
Add Comment
Please, Sign In to add comment