Skip to content

Commit

Permalink
Fix inefficient use of keySet iterator instead of entrySet iterator (#…
Browse files Browse the repository at this point in the history
…3508)

Fix inefficient use of keySet iterator instead of entrySet iterator
  • Loading branch information
Hiroaki Yoshida authored and carryxyh committed Feb 20, 2019
1 parent aadf57d commit e918fa4
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@ public static <T> ProviderInvokerWrapper<T> getProviderWrapper(URL registeredPro
return null;
}

for (Invoker inv : invokers.keySet()) {
if (inv == invoker) {
return invokers.get(inv);
for (Map.Entry<Invoker, ProviderInvokerWrapper> entry : invokers.entrySet()) {
if (entry.getKey() == invoker) {
return entry.getValue();
}
}

Expand Down

0 comments on commit e918fa4

Please sign in to comment.