-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.php
executable file
·27 lines (24 loc) · 1.09 KB
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php
@include_once __DIR__ . '/vendor/autoload.php';
Kirby::plugin('genxbe/ray', [
'options' => [
'enabled' => false,
],
'pageMethods' => ['ray' => fn ($color = null) => X\Ray::ray($this, $color)],
'pagesMethods' => ['ray' => fn ($color = null) => X\Ray::ray($this, $color)],
'fieldMethods' => ['ray' => fn ($field, $color = null) => X\Ray::ray($field, $color)],
'siteMethods' => ['ray' => fn ($color = null) => X\Ray::ray($this, $color)],
'fileMethods' => ['ray' => fn ($color = null) => X\Ray::ray($this, $color)],
'filesMethods' => ['ray' => fn ($color = null) => X\Ray::ray($this, $color)],
'userMethods' => ['ray' => fn ($color = null) => X\Ray::ray($this, $color)],
'usersMethods' => ['ray' => fn ($color = null) => X\Ray::ray($this, $color)],
'collectionMethods' => ['ray' => fn ($color = null) => X\Ray::ray($this, $color)],
'hooks' => [
'system.exception' => function ($exception) {
ray()->exception($exception);
},
],
]);
if (function_exists('ray') && (!option('debug') && !option('genxbe.ray.enabled'))) {
ray()->disable();
}