public function getMode()
    {
        if (!isset($this->mode)) {
            if (isset($_ENV['SLIM_MODE'])) {
                $this->mode = $_ENV['SLIM_MODE'];
            } else {
                $envMode = getenv('SLIM_MODE');
                if ($envMode !== false) {
                    $this->mode = $envMode;
                } else {
                    $this->mode = $this->config('mode');
                }
            }
        }

        return $this->mode;
    }
public function getMode()
    {
        if (!isset($this->mode)) {
            if (isset($_ENV['SLIM_MODE'])) {
                $this->mode = $_ENV['SLIM_MODE'];
            } else {
                $envMode = getenv('SLIM_MODE');
                if ($envMode !== false) {
                    $this->mode = $envMode;
                } else {
                    $this->mode = $this->config('mode');
                }
            }
        }

        return $this->mode;
    }
public function getMode ( ) { if ( ! isset ( $ this -> mode ) ) { if ( isset ( $ _ENV [ 'SLIM_MODE' ] ) ) { $ this -> mode = $ _ENV [ 'SLIM_MODE' ] ; } else { $ envMode = getenv ( 'SLIM_MODE' ) ; if ( $ envMode !== false ) { $ this -> mode = $ envMode ; } else { $ this -> mode = $ this -> config ( 'mode' ) ; } } } return $ this -> mode ; }
Get application mode

This method determines the application mode. It first inspects the $_ENV
superglobal for key `SLIM_MODE`. If that is not found, it queries
the `getenv` function. Else, it uses the application `mode` setting.

@return string
Get application mode