Skip to content
This repository was archived by the owner on Aug 15, 2023. It is now read-only.

Commit 0f3560c

Browse files
committed
[FIX] fix DatabaseApiService
1 parent f08863c commit 0f3560c

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Classes/Service/DatabaseApiService.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,13 @@ class Tx_Coreapi_Service_DatabaseApiService {
4848
* Constructor function
4949
*/
5050
public function __construct() {
51-
$this->sqlHandler = t3lib_div::makeInstance('t3lib_install_Sql');
51+
if (class_exists('TYPO3\\CMS\\Install\\Sql\\SchemaMigrator')) {
52+
$this->sqlHandler = t3lib_div::makeInstance('TYPO3\\CMS\\Install\\Sql\\SchemaMigrator');
53+
} elseif (class_exists('t3lib_install_Sql')) {
54+
$this->sqlHandler = t3lib_div::makeInstance('t3lib_install_Sql');
55+
} elseif (class_exists('t3lib_install')) {
56+
$this->sqlHandler = t3lib_div::makeInstance('t3lib_install');
57+
}
5258
}
5359

5460
/**

0 commit comments

Comments
 (0)