update src/Mongodb.php.

This commit is contained in:
Adam 2020-07-24 17:55:26 +08:00 committed by Gitee
parent 9ebee15441
commit 9b56b4e360

View File

@ -239,7 +239,7 @@ class Mongodb
if ($hasContextConnection) { if ($hasContextConnection) {
$connection = Context::get($this->getContextKey()); $connection = Context::get($this->getContextKey());
} }
if (!$connection instanceof MongoDbConnection) { if (!$connection instanceof MongodbConnection) {
$pool = $this->factory->getPool($this->poolName); $pool = $this->factory->getPool($this->poolName);
$connection = $pool->get()->getConnection(); $connection = $pool->get()->getConnection();
} }