KickstartForm: prepare for utf8mb4

This commit is contained in:
Thomas Gelf 2017-03-13 21:59:51 +01:00
parent 158ce18302
commit a36ed2c23d
1 changed files with 2 additions and 2 deletions

View File

@ -169,7 +169,7 @@ class KickstartForm extends QuickForm
if ($resourceName = $this->getResourceName()) {
$resourceConfig = ResourceFactory::getResourceConfig($resourceName);
if (! isset($resourceConfig->charset)
|| $resourceConfig->charset !== 'utf8'
|| ! in_array($resourceConfig->charset, array('utf8', 'utf8mb4'))
) {
$this->getElement('resource')
->addError('Please change the encoding for the director database to utf8');
@ -340,7 +340,7 @@ class KickstartForm extends QuickForm
$kickstart->setConfig($values)->run();
parent::onSuccess();
} catch (Exception $e) {
$this->addError($e->getMessage());
$this->addException($e);
}
}