This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-pool.git


The following commit(s) were added to refs/heads/master by this push:
     new 7a0dffb  Use isEmpty().
7a0dffb is described below

commit 7a0dffb21b5e2689a2b38596985792681cca355b
Author: Gary Gregory <gardgreg...@gmail.com>
AuthorDate: Sat Jan 16 22:31:43 2021 -0500

    Use isEmpty().
---
 src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java 
b/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java
index 7d182ab..c1c358f 100644
--- a/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java
+++ b/src/main/java/org/apache/commons/pool2/impl/GenericObjectPool.java
@@ -738,7 +738,7 @@ public class GenericObjectPool<T> extends 
BaseGenericObjectPool<T>
     public void evict() throws Exception {
         assertOpen();
 
-        if (idleObjects.size() > 0) {
+        if (!idleObjects.isEmpty()) {
 
             PooledObject<T> underTest = null;
             final EvictionPolicy<T> evictionPolicy = getEvictionPolicy();

Reply via email to