if (list == null) {
list = manager.createPrivacyList(from.getNode(), listName, listElement);
}
else {
// Update existing list
list.updateList(listElement);
provider.updatePrivacyList(from.getNode(), list);
// Make sure that existing user sessions that are using the updated list are poining
// to the updated instance. This may happen since PrivacyListManager uses a Cache that
// may expire so it's possible to have many instances representing the same privacy
// list. Therefore, if a list is modified then we need to make sure that all