diff --git a/PoolItem.php b/PoolItem.php index 00af038..c73d5d6 100644 --- a/PoolItem.php +++ b/PoolItem.php @@ -141,7 +141,7 @@ class PoolItem */ public function pop(int $waite = 10): mixed { - if ($this->_items->isEmpty() && $this->created >= $this->maxCreated) { + if ($this->_items->isEmpty() && $this->created < $this->maxCreated) { $this->created += 1; return call_user_func($this->callback); } else {