aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/Setup.php
diff options
context:
space:
mode:
authorDaniel Kesselberg <mail@danielkesselberg.de>2021-07-05 09:49:05 +0200
committerDaniel Kesselberg <mail@danielkesselberg.de>2021-07-05 09:49:05 +0200
commitc91bb98e5ce0e1bd0775411a19d19f8eb862e285 (patch)
treee67f3ee94da967c68a5e52b0ba1b183f76ba2c49 /lib/private/Setup.php
parentbb22d38aa10e58de0103aa57ecbdf60b167c59bb (diff)
downloadnextcloud-server-c91bb98e5ce0e1bd0775411a19d19f8eb862e285.tar.gz
nextcloud-server-c91bb98e5ce0e1bd0775411a19d19f8eb862e285.zip
Check that pdo is installed
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
Diffstat (limited to 'lib/private/Setup.php')
-rw-r--r--lib/private/Setup.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/private/Setup.php b/lib/private/Setup.php
index d39fa069286..a4873e63aa9 100644
--- a/lib/private/Setup.php
+++ b/lib/private/Setup.php
@@ -131,7 +131,10 @@ class Setup {
* @return array
*/
protected function getAvailableDbDriversForPdo() {
- return \PDO::getAvailableDrivers();
+ if (class_exists(\PDO::class)) {
+ return \PDO::getAvailableDrivers();
+ }
+ return [];
}
/**