if (password != null && !password.equals("")) { try { user.setPassword(SecurityUtil.digestString(password, ServerSettings.getSetting("default.registry.password.hash.method"))); } catch (NoSuchAlgorithmException e) { if (password != null && !password.equals("")) { try { existingUser.setPassword(SecurityUtil.digestString(password, ServerSettings.getSetting("default.registry.password.hash.method"))); } catch (NoSuchAlgorithmException e) {
if (password != null && !password.equals("")) { try { user.setPassword(SecurityUtil.digestString(password, ServerSettings.getSetting("default.registry.password.hash.method"))); } catch (NoSuchAlgorithmException e) { if (password != null && !password.equals("")) { try { existingUser.setPassword(SecurityUtil.digestString(password, ServerSettings.getSetting("default.registry.password.hash.method"))); existingUser.setGatewayId(gateway.getGatewayId());