diff --git a/System/Abstracts/Pool.php b/System/Abstracts/Pool.php index 0965a7be..44619c76 100644 --- a/System/Abstracts/Pool.php +++ b/System/Abstracts/Pool.php @@ -43,6 +43,9 @@ abstract class Pool extends Component */ protected function get($name) { + if ($this->_items[$name]->length() < 1) { + return [0, null]; + } [$timeout, $connection] = $this->_items[$name]->pop(); if (!$this->checkCanUse($name, $timeout, $connection)) { unset($client);