mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-17 18:51:10 +01:00
fix possible concurrent modification exception
This commit is contained in:
@@ -34,6 +34,7 @@ package sonia.scm.xml;
|
|||||||
|
|
||||||
//~--- non-JDK imports --------------------------------------------------------
|
//~--- non-JDK imports --------------------------------------------------------
|
||||||
|
|
||||||
|
import com.google.common.collect.ImmutableList;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
@@ -229,7 +230,8 @@ public abstract class AbstractXmlDAO<I extends ModelObject,
|
|||||||
@Override
|
@Override
|
||||||
public Collection<I> getAll()
|
public Collection<I> getAll()
|
||||||
{
|
{
|
||||||
return db.values();
|
// avoid concurrent modification exceptions
|
||||||
|
return ImmutableList.copyOf(db.values());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user