Browse Source

Fix concurrent modification exception when switching root

Guy Carmeli 8 years ago
parent
commit
04ad06ca11

+ 1
- 1
android/app/src/main/java/com/reactnativenavigation/events/EventBus.java View File

@@ -21,7 +21,7 @@ public enum EventBus {
21 21
             WeakReference<Subscriber> ref = iterator.next();
22 22
             Subscriber registered = ref.get();
23 23
             if (registered != null && registered == subscriber) {
24
-                subscribers.remove(ref);
24
+                iterator.remove();
25 25
             }
26 26
         }
27 27
     }