Subversion Repositories SmartDukaan

Rev

Rev 26834 | Rev 26842 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 26834 Rev 26840
Line 43... Line 43...
43
		try {
43
		try {
44
			customer = customerRepository.selectByMobileNumber(customer.getMobileNumber());
44
			customer = customerRepository.selectByMobileNumber(customer.getMobileNumber());
45
		} catch (ProfitMandiBusinessException pbse) {
45
		} catch (ProfitMandiBusinessException pbse) {
46
			if(customer.getPassword()!=null) {
46
			if(customer.getPassword()!=null) {
47
				customer.setPassword(getHash256(customer.getPassword()));
47
				customer.setPassword(getHash256(customer.getPassword()));
-
 
48
			} else {
-
 
49
				customer.setPassword(getHash256(getRandomString()));
48
			}
50
			}
49
			customer.setPassword(getHash256(getRandomString()));
-
 
50
			try {
51
			try {
51
				customerRepository.persist(customer);
52
				customerRepository.persist(customer);
52
			} catch(Exception e) {
53
			} catch(Exception e) {
53
				e.printStackTrace();
54
				e.printStackTrace();
54
			}
55
			}