Skip to content
Snippets Groups Projects
Commit 38019d12 authored by Thomas Mortagne's avatar Thomas Mortagne
Browse files

XWIKI-13760: Repository Application is missing allowed namespaces field in the class

parent 761b9b5a
No related branches found
No related tags found
No related merge requests found
......@@ -1072,6 +1072,13 @@ protected <T> T getValue(BaseObject object, String field, T def)
protected boolean update(BaseObject object, String fieldName, Object value)
{
// Make sure collection are lists
if (value instanceof Collection) {
if (!(value instanceof List)) {
value = new ArrayList<>((Collection) value);
}
}
if (ObjectUtils.notEqual(value, getValue(object, fieldName))) {
object.set(fieldName, value, this.xcontextProvider.get());
......
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