Skip to content

Commit 5610d20

Browse files
authored
[feature] Added support for doctrine dbal 3 (#257)
1 parent fee4f68 commit 5610d20

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Check/DoctrineDbal.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,13 @@ public function check()
2121
{
2222
$connection = $this->manager->getConnection($this->connectionName);
2323
$query = $connection->getDriver()->getDatabasePlatform()->getDummySelectSQL();
24-
$connection->fetchColumn($query);
24+
25+
// after dbal 2.11 fetchOne replace fetchColumn
26+
if (method_exists($connection, 'fetchOne')) {
27+
$connection->fetchOne($query);
28+
} else {
29+
$connection->fetchColumn($query);
30+
}
2531

2632
return new Success();
2733
}

0 commit comments

Comments
 (0)