- A lot of fixes done on this for a test project.
This commit is contained in:
1 parent
52e55f2bba
commit
09b3e47c19
11 files changed
+78
-21
No files matched your search
+10
-3
@@ -11,6 +11,7 @@ use League\Route\Strategy\ApplicationStrategy;
|
||||
|
||||
use Psr\Http\Message\ServerRequestInterface;
|
||||
|
||||
use Tell\I18n;
|
||||
use Ulmus\Container\AdapterProxy;
|
||||
|
||||
use Zend\Diactoros\ServerRequestFactory,
|
||||
@@ -82,7 +83,7 @@ class Kernel {
|
||||
|
||||
ini_set("log_errors", "1");
|
||||
ini_set("error_log", $this->errorLogPath);
|
||||
ini_set('display_errors', getenv("DEBUG") ? 'on' : 'off');
|
||||
ini_set('display_errors', getenv("DEBUG") ? 'on' : 'on');
|
||||
|
||||
error_reporting($this->errorReporting);
|
||||
|
||||
@@ -95,8 +96,8 @@ class Kernel {
|
||||
|
||||
if (getenv("APP_ENV") === "prod") {
|
||||
if (getenv("CACHE_PATH")) {
|
||||
$containerBuilder->enableCompilation(getenv("CACHE_PATH") . "/di/");
|
||||
$containerBuilder->writeProxiesToFile(true);
|
||||
# $containerBuilder->enableCompilation(getenv("CACHE_PATH") . "/di/");
|
||||
# $containerBuilder->writeProxiesToFile(true);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -116,6 +117,12 @@ class Kernel {
|
||||
$this->container->has(AdapterProxy::class) and $this->container->get(AdapterProxy::class);
|
||||
$this->container->has(Lean::class) and $this->container->get(Lean::class);
|
||||
|
||||
if ($this->container->has(I18n::class)) {
|
||||
$i18n = $this->container->get(I18n::class);
|
||||
$i18n->locale($this->locale);
|
||||
$i18n->initialize(!getenv("DEBUG"));
|
||||
}
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user