Skip to content
Snippets Groups Projects
Commit d5bfa705 authored by srosse's avatar srosse
Browse files

OO-230: reduce the level of the log for duplicates v2guipreferences

parent 50d13273
No related branches found
No related tags found
No related merge requests found
......@@ -100,10 +100,9 @@ public class DbStorage extends LogDelegator implements PreferencesStorage{
// OLAT-6429 detect and delete multiple prefs objects, keep the first one only
List<Property> guiPropertyList = PropertyManager.getInstance().findProperties(identity, null, null, null, USER_PROPERTY_KEY);
if (guiPropertyList != null && guiPropertyList.size() > 0) {
logError("Found more than 1 entry for " + USER_PROPERTY_KEY + " in o_property table for user " + identity.getName() + ". Use first of them, deleting the others!", e);
guiProperty = guiPropertyList.get(0);
logWarn("Found more than 1 entry for " + USER_PROPERTY_KEY + " in o_property table for user " + identity.getName() + ". Use first of them, deleting the others!", e);
Iterator<Property> iterator = guiPropertyList.iterator();
iterator.next();
guiProperty = iterator.next();
while (iterator.hasNext()) {
Property property = iterator.next();
PropertyManager.getInstance().deleteProperty(property);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment