Conditions | 4 |
Paths | 3 |
Total Lines | 12 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
18 | public function init() |
||
19 | { |
||
20 | if (!empty(SentrySdk::getCurrentHub()->getClient())) { |
||
21 | return; |
||
22 | } |
||
23 | $params = Yii::$app->params; |
||
24 | if (empty($params['sentry.dsn']) || empty($params['sentry.enabled'])) { |
||
25 | return; |
||
26 | } |
||
27 | |||
28 | \Sentry\init(['dsn' => $params['sentry.dsn']]); |
||
29 | } |
||
30 | } |
||
31 |