Skip to content

Commit

Permalink
Issue-186: Solving JDK8-JDK7 compatibility issue with ConcurrentHashM…
Browse files Browse the repository at this point in the history
…ap.keySet()
  • Loading branch information
dlemures committed Jan 18, 2017
1 parent 586edc2 commit 1f7e1fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions toothpick-runtime/src/main/java/toothpick/Toothpick.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package toothpick;

import java.util.ArrayList;
import java.util.Collections;
import java.util.concurrent.ConcurrentHashMap;
import toothpick.configuration.Configuration;
import toothpick.configuration.ConfigurationHolder;
Expand Down Expand Up @@ -122,7 +122,7 @@ public static void closeScope(Object name) {
*/

public static void reset() {
for (Object name : new ArrayList<>(MAP_KEY_TO_SCOPE.keySet())) {
for (Object name : Collections.list(MAP_KEY_TO_SCOPE.keys())) {
closeScope(name);
}
ConfigurationHolder.configuration.onScopeForestReset();
Expand Down

0 comments on commit 1f7e1fb

Please sign in to comment.