1 install.inc | protected DatabaseTasks::checkUtf8mb4() |
Check the engine version.
File
- core/
includes/ install.inc, line 566 - API functions for installing modules and themes.
Class
- DatabaseTasks
- Database installer structure.
Code
protected function checkUtf8mb4() {
$connection = Database::getConnection();
$connection_info = Database::getConnectionInfo();
if (!$connection->utf8mb4IsActive()) {
if ($connection->utf8mb4IsSupported()) {
$connection_info['default']['charset'] = 'utf8mb4';
Database::removeConnection('default');
Database::addConnectionInfo('default', 'default', $connection_info['default']);
Database::getConnection();
}
}
}