blob: a6232cf42994edf117eee05ec8e016b688b61b52 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
<?php
error_reporting(0);
require_once __DIR__.'/../vendor/autoload.php';
$savedConfig = __DIR__.'/../custom/config.yml';
$moon_version = file_get_contents(__DIR__.'/../VERSION');
if (is_installed()) {
$conf = Spyc::YAMLLoad($savedConfig);
// this is a check to upgrade older config file without l10n
if(!isset($conf['locale'])) {
$resetPlanetConfig = new PlanetConfig($conf);
file_put_contents($savedConfig, $resetPlanetConfig->toYaml());
$conf = Spyc::YAMLLoad($savedConfig);
}
$PlanetConfig = new PlanetConfig($conf);
$Planet = new Planet($PlanetConfig);
if ($conf['debug']) {
error_reporting(E_ALL);
}
}
$l10n = new Simplel10n($conf['locale']);
|