1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-09-20 08:21:34 +02:00

Remove Laravel Telescope (#2488)

This commit is contained in:
David Bomba 2018-11-03 12:22:43 +11:00 committed by GitHub
parent 3b0cda1502
commit db8f962d9b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 1 additions and 258 deletions

View File

@ -23,7 +23,6 @@ class AuthServiceProvider extends ServiceProvider
* @return void * @return void
*/ */
/*
public function boot() public function boot()
{ {
$this->registerPolicies(); $this->registerPolicies();
@ -37,16 +36,5 @@ class AuthServiceProvider extends ServiceProvider
}); });
} }
*/
public function register()
{
Auth::provider('users', function ($app, array $config) {
return new MultiDatabaseUserProvider($this->app['hash'], $config['model']);
});
Auth::provider('contacts', function ($app, array $config) {
return new MultiDatabaseUserProvider($this->app['hash'], $config['model']);
});
}
} }

View File

@ -1,49 +0,0 @@
<?php
namespace App\Providers;
use Laravel\Telescope\Telescope;
use Illuminate\Support\Facades\Gate;
use Laravel\Telescope\IncomingEntry;
use Laravel\Telescope\TelescopeApplicationServiceProvider;
class TelescopeServiceProvider extends TelescopeApplicationServiceProvider
{
/**
* Register any application services.
*
* @return void
*/
public function register()
{
// Telescope::night();
Telescope::filter(function (IncomingEntry $entry) {
if ($this->app->isLocal()) {
return true;
}
return $entry->isReportableException() ||
$entry->isFailedJob() ||
$entry->isScheduledTask() ||
$entry->hasMonitoredTag();
});
}
/**
* Register the Telescope gate.
*
* This gate determines who can access Telescope in non-local environments.
*
* @return void
*/
protected function gate()
{
Gate::define('viewTelescope', function ($user) {
return in_array($user->email, [
//
]);
});
}
}

View File

@ -26,7 +26,6 @@
"laracasts/presenter": "^0.2.1", "laracasts/presenter": "^0.2.1",
"laravel/framework": "5.7.*", "laravel/framework": "5.7.*",
"laravel/socialite": "^3.1", "laravel/socialite": "^3.1",
"laravel/telescope": "^0.1.6",
"laravel/tinker": "^1.0", "laravel/tinker": "^1.0",
"nwidart/laravel-modules": "^4.0", "nwidart/laravel-modules": "^4.0",
"predis/predis": "^1.1", "predis/predis": "^1.1",

114
composer.lock generated
View File

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "a67265303c8a08e7564c887c1e040664", "content-hash": "753b0ff8fa34e1e5a54d950d3d780d30",
"packages": [ "packages": [
{ {
"name": "asgrim/ofxparser", "name": "asgrim/ofxparser",
@ -1065,69 +1065,6 @@
], ],
"time": "2018-10-18T03:39:04+00:00" "time": "2018-10-18T03:39:04+00:00"
}, },
{
"name": "laravel/telescope",
"version": "v0.1.6",
"source": {
"type": "git",
"url": "https://github.com/laravel/telescope.git",
"reference": "e3dbda59367969222603a2a20f0ee3aabe7bcdce"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/laravel/telescope/zipball/e3dbda59367969222603a2a20f0ee3aabe7bcdce",
"reference": "e3dbda59367969222603a2a20f0ee3aabe7bcdce",
"shasum": ""
},
"require": {
"ext-json": "*",
"laravel/framework": "~5.7.7",
"moontoast/math": "^1.1",
"php": "^7.1.3",
"symfony/var-dumper": "^4.1"
},
"require-dev": {
"nunomaduro/larastan": "^0.3.7",
"orchestra/testbench": "~3.7"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.0-dev"
},
"laravel": {
"providers": [
"Laravel\\Telescope\\TelescopeServiceProvider"
]
}
},
"autoload": {
"psr-4": {
"Laravel\\Telescope\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Taylor Otwell",
"email": "taylor@laravel.com"
},
{
"name": "Mohamed Said",
"email": "mohamed@laravel.com"
}
],
"description": "An elegant debug assistant for the Laravel framework.",
"keywords": [
"debugging",
"laravel",
"monitoring"
],
"time": "2018-11-02T10:45:19+00:00"
},
{ {
"name": "laravel/tinker", "name": "laravel/tinker",
"version": "v1.0.8", "version": "v1.0.8",
@ -1709,55 +1646,6 @@
], ],
"time": "2017-06-19T01:22:40+00:00" "time": "2017-06-19T01:22:40+00:00"
}, },
{
"name": "moontoast/math",
"version": "1.1.2",
"source": {
"type": "git",
"url": "https://github.com/ramsey/moontoast-math.git",
"reference": "c2792a25df5cad4ff3d760dd37078fc5b6fccc79"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/ramsey/moontoast-math/zipball/c2792a25df5cad4ff3d760dd37078fc5b6fccc79",
"reference": "c2792a25df5cad4ff3d760dd37078fc5b6fccc79",
"shasum": ""
},
"require": {
"ext-bcmath": "*",
"php": ">=5.3.3"
},
"require-dev": {
"jakub-onderka/php-parallel-lint": "^0.9.0",
"phpunit/phpunit": "^4.7|>=5.0 <5.4",
"satooshi/php-coveralls": "^0.6.1",
"squizlabs/php_codesniffer": "^2.3"
},
"type": "library",
"autoload": {
"psr-4": {
"Moontoast\\Math\\": "src/Moontoast/Math/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"Apache-2.0"
],
"authors": [
{
"name": "Ben Ramsey",
"email": "ben@benramsey.com",
"homepage": "https://benramsey.com"
}
],
"description": "A mathematics library, providing functionality for large numbers",
"homepage": "https://github.com/ramsey/moontoast-math",
"keywords": [
"bcmath",
"math"
],
"time": "2017-02-16T16:54:46+00:00"
},
{ {
"name": "nesbot/carbon", "name": "nesbot/carbon",
"version": "1.34.0", "version": "1.34.0",

View File

@ -178,7 +178,6 @@ return [
App\Providers\AuthServiceProvider::class, App\Providers\AuthServiceProvider::class,
// App\Providers\BroadcastServiceProvider::class, // App\Providers\BroadcastServiceProvider::class,
App\Providers\EventServiceProvider::class, App\Providers\EventServiceProvider::class,
App\Providers\TelescopeServiceProvider::class,
App\Providers\RouteServiceProvider::class, App\Providers\RouteServiceProvider::class,
], ],

View File

@ -1,82 +0,0 @@
<?php
use Laravel\Telescope\Watchers;
use Laravel\Telescope\Http\Middleware\Authorize;
return [
'path' => 'telescope',
/*
|--------------------------------------------------------------------------
| Telescope Storage Driver
|--------------------------------------------------------------------------
|
| This configuration options determines the storage driver that will
| be used to store Telescope's data. In addition, you may set any
| custom options as needed by the particular driver you choose.
|
*/
'driver' => env('TELESCOPE_DRIVER', 'database'),
'storage' => [
'database' => [
'connection' => env('DB_CONNECTION', 'mysql'),
],
],
/*
|--------------------------------------------------------------------------
| Telescope Route Middleware
|--------------------------------------------------------------------------
|
| These middleware will be assigned to every Telescope route, giving you
| the chance to add your own middleware to this list or change any of
| the existing middleware. Or, you can simply stick with this list.
|
*/
'middleware' => [
'web',
Authorize::class,
],
/*
|--------------------------------------------------------------------------
| Telescope Watchers
|--------------------------------------------------------------------------
|
| The following array lists the "watchers" that will be registered with
| Telescope. The watchers gather the application's profile data when
| a request or task is executed. Feel free to customize this list.
|
*/
'watchers' => [
Watchers\CacheWatcher::class => env('TELESCOPE_CACHE_WATCHER', true),
Watchers\CommandWatcher::class => env('TELESCOPE_COMMAND_WATCHER', true),
Watchers\DumpWatcher::class => env('TELESCOPE_DUMP_WATCHER', true),
Watchers\EventWatcher::class => env('TELESCOPE_EVENT_WATCHER', true),
Watchers\ExceptionWatcher::class => env('TELESCOPE_EXCEPTION_WATCHER', true),
Watchers\JobWatcher::class => env('TELESCOPE_JOB_WATCHER', true),
Watchers\LogWatcher::class => env('TELESCOPE_LOG_WATCHER', true),
Watchers\MailWatcher::class => env('TELESCOPE_MAIL_WATCHER', true),
Watchers\ModelWatcher::class => env('TELESCOPE_MODEL_WATCHER', true),
Watchers\NotificationWatcher::class => env('TELESCOPE_NOTIFICATION_WATCHER', true),
Watchers\QueryWatcher::class => [
'enabled' => env('TELESCOPE_QUERY_WATCHER', true),
'slow' => 100,
],
Watchers\RedisWatcher::class => env('TELESCOPE_REDIS_WATCHER', true),
Watchers\RequestWatcher::class => [
'enabled' => env('TELESCOPE_REQUEST_WATCHER', true),
'size_limit' => env('TELESCOPE_REQUEST_SIZE_LIMIT', 64),
],
Watchers\ScheduleWatcher::class => env('TELESCOPE_SCHEDULE_WATCHER', true),
],
];