modify plugin name

This commit is contained in:
2022-07-11 17:05:32 +08:00
parent cd509b2663
commit 150cdbbbfa
2 changed files with 7 additions and 5 deletions
+3 -1
View File
@@ -89,7 +89,9 @@ class Pool extends Component
$lists = []; $lists = [];
$count = $channel->length(); $count = $channel->length();
while ($this->status->is(StatusEnum::EXIT) === false) { while ($this->status->is(StatusEnum::EXIT) === false) {
$pdo = $channel->pop(); if (!(($pdo = $channel->pop()) instanceof PDO)) {
break;
}
if ($pdo->check()) { if ($pdo->check()) {
$success += 1; $success += 1;
} }
+4 -4
View File
@@ -17,11 +17,11 @@ class PoolQueue implements QueueInterface
*/ */
public function __construct(public int $max) public function __construct(public int $max)
{ {
// if (Context::inCoroutine()) { if (Context::inCoroutine()) {
// $this->queue = new Channel($this->max); $this->queue = new Channel($this->max);
// } else { } else {
$this->queue = new SplQueue($this->max); $this->queue = new SplQueue($this->max);
// } }
} }