Skip to content

Commit fab6502

Browse files
committed
rv telescope class
1 parent 4c3fd12 commit fab6502

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

bootstrap/providers.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
App\Providers\AppServiceProvider::class,
55
];
66

7-
// Telescopeはローカル環境でのみ有効化
8-
if (app()->environment('local')) {
7+
// Telescopeはローカル環境でのみ有効化(クラスが存在する場合のみ)
8+
if (app()->environment('local') && class_exists(\Laravel\Telescope\TelescopeApplicationServiceProvider::class)) {
99
$providers[] = App\Providers\TelescopeServiceProvider::class;
1010
}
1111

config/telescope.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
|
1717
*/
1818

19-
'enabled' => env('TELESCOPE_ENABLED', false),
19+
'enabled' => env('TELESCOPE_ENABLED', env('APP_ENV') === 'local'),
2020

2121
/*
2222
|--------------------------------------------------------------------------

0 commit comments

Comments
 (0)