newIssue('php.date.timezone') ->setShortName(pht('PHP Timezone')) ->setName(pht('PHP Timezone Invalid')) ->setMessage($message) ->addPHPConfig('date.timezone'); } } $timezone = nonempty( PhabricatorEnv::getEnvConfig('phabricator.timezone'), ini_get('date.timezone')); if ($timezone) { return; } $summary = pht( 'Without a configured timezone, PHP will emit warnings when working '. 'with dates, and dates and times may not display correctly.'); $message = pht( "Your configuration fails to specify a server timezone. You can either ". "set the PHP configuration value '%s' or the Phabricator ". "configuration value '%s' to specify one.", 'date.timezone', 'phabricator.timezone'); $this ->newIssue('config.timezone') ->setShortName(pht('Timezone')) ->setName(pht('Server Timezone Not Configured')) ->setSummary($summary) ->setMessage($message) ->addPHPConfig('date.timezone') ->addPhabricatorConfig('phabricator.timezone'); } }