/**
  * Determines whether a server is running in production mode.
  *
  * @return bool
  */
 public static function isProduction()
 {
     if (self::$productionMode === null) {
         self::$productionMode = !Nette\Config\Configurator::detectDebugMode();
     }
     return self::$productionMode;
 }
Example #2
0
 /**
  * Enables or disables production mode.
  * @param  bool
  * @return void
  */
 public static function setProductionMode($value = TRUE)
 {
     self::$productionMode = (bool) $value;
 }
Example #3
0
 /**
  * Enables or disables production mode.
  * @param  bool
  * @return void
  */
 public static function setProductionMode($value = TRUE)
 {
     trigger_error(__CLASS__ . ' is deprecated.', E_USER_DEPRECATED);
     self::$productionMode = (bool) $value;
 }