5 * Determine whether Civi has been installed.
8 if (!defined('CIVI_SETUP')) {
9 exit("Installation plugins must only be loaded by the installer.\n");
12 \Civi\Setup
::dispatcher()
13 ->addListener('civi.setup.checkInstalled', function (\Civi\Setup\Event\CheckInstalledEvent
$e) {
14 \Civi\Setup
::log()->info(sprintf('[%s] Handle %s', basename(__FILE__
), 'checkInstalled'));
16 $model = $e->getModel();
18 if ($model->settingsPath
) {
19 $e->setSettingInstalled(file_exists($model->settingsPath
));
22 throw new \
Exception("The \"settingsPath\" is unspecified. Cannot determine whether the settings file exists.");