File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ require_once($_SERVER['DOCUMENT_ROOT'] . '/vendor/autoload.php');
2929
3030### Определение переменных
3131
32- Для получения окружения и URL используется функция ` getenv() ` , поэтому в .env файле нужно определить две переменные:
32+ Для установки окружения и URL sentry в .env файле нужно определить две переменные:
3333
3434``` dotenv
3535APP_ENV=production
Original file line number Diff line number Diff line change @@ -51,13 +51,13 @@ public function initialize(array $options)
5151 */
5252 public function initSentry ():void
5353 {
54- $ environment = getenv ( 'APP_ENV ' ) ;
54+ $ environment = $ _ENV [ 'APP_ENV ' ] ;
5555
5656 // инициализация Sentry
5757 if ($ environment && $ environment !== 'local ' && function_exists ('Sentry\init ' )) {
5858 init (
5959 [
60- 'dsn ' => getenv ( 'SENTRY_DSN ' ) ,
60+ 'dsn ' => $ _ENV [ 'SENTRY_DSN ' ] ,
6161 'environment ' => $ environment ,
6262 'error_types ' => $ this ->level
6363 ]
You can’t perform that action at this time.
0 commit comments