Nette 2.2@dev Fatal error: Undefined class constant ‘DEVELOPMENT’

Notice: This thread is very old.
motorcb
Member | 534
+
0
-

I'm using Nette 2.2@dev. Composer: “nette/nette”: "@dev",
and set debug mode:

$array = array("192.168.1.82");
$prod = !$configurator->detectDebugMode( $array );
$configurator->addParameters(array(
    "environment" => $prod ? $configurator::PRODUCTION : $configurator::DEVELOPMENT,
    "productionMode" => $prod,
    "debugMode" => !$prod,
));

Show error: Fatal error: Undefined class constant ‘DEVELOPMENT’ in /var/www/clients/client1/web4/web/ebus/app/bootstrap.php on line 13

Why can't load constatnt DEVELOPMENT?

Last edited by motorcb (2013-12-16 21:49)

enumag
Member | 2118
+
0
-

Because these constants are deprecated in 2.1 and removed in master.

David Grudl
Nette Core | 7418
+
0
-

These constants are deprecated, use just strings ‘development’ and ‘production’.