Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove unused imports #1404

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions src/Controllers/CacheController.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@

namespace Barryvdh\Debugbar\Controllers;

use Illuminate\Http\Response;

class CacheController extends BaseController
{
/**
Expand Down
3 changes: 0 additions & 3 deletions src/Controllers/TelescopeController.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@

namespace Barryvdh\Debugbar\Controllers;

use Barryvdh\Debugbar\Support\Clockwork\Converter;
use DebugBar\OpenHandler;
use Illuminate\Http\Response;
use Laravel\Telescope\Contracts\EntriesRepository;
use Laravel\Telescope\IncomingEntry;
use Laravel\Telescope\Storage\EntryQueryOptions;
Expand Down
1 change: 0 additions & 1 deletion src/DataCollector/EventCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
use DebugBar\DataCollector\TimeDataCollector;
use Illuminate\Contracts\Events\Dispatcher;
use Illuminate\Support\Str;
use Symfony\Component\VarDumper\Cloner\VarCloner;

class EventCollector extends TimeDataCollector
{
Expand Down
1 change: 0 additions & 1 deletion src/DataCollector/GateCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
use Illuminate\Auth\Access\Response;
use Illuminate\Contracts\Auth\Access\Gate;
use Illuminate\Contracts\Auth\Authenticatable;
use Symfony\Component\VarDumper\Cloner\VarCloner;
use Illuminate\Support\Str;

/**
Expand Down
4 changes: 0 additions & 4 deletions src/DataCollector/LivewireCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,8 @@
use DebugBar\DataCollector\DataCollector;
use DebugBar\DataCollector\DataCollectorInterface;
use DebugBar\DataCollector\Renderable;
use Illuminate\Contracts\Events\Dispatcher;
use Illuminate\Contracts\View\View;
use Illuminate\Http\Request;
use Illuminate\Support\Arr;
use Illuminate\Support\Fluent;
use Illuminate\Support\Str;
use Livewire\Livewire;

/**
Expand Down
3 changes: 0 additions & 3 deletions src/DataCollector/MultiAuthCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,8 @@

use DebugBar\DataCollector\DataCollector;
use DebugBar\DataCollector\Renderable;
use Illuminate\Auth\Recaller;
use Illuminate\Auth\SessionGuard;
use Illuminate\Contracts\Auth\Authenticatable;
use Illuminate\Contracts\Auth\Guard;
use Illuminate\Support\Str;
use Illuminate\Contracts\Support\Arrayable;

/**
Expand Down
2 changes: 0 additions & 2 deletions src/DataCollector/RouteCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
use Closure;
use DebugBar\DataCollector\DataCollector;
use DebugBar\DataCollector\Renderable;
use Illuminate\Http\Request;
use Illuminate\Routing\Route;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it can be removed, since the import is not used anywhere, but I would suggest to keep the import of the Response class and use it here

if (!is_a($route, 'Illuminate\Routing\Route')) {

as Response::class instead of a string value

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you're free to make a separate PR, but I'm going to leave this as is.

use Illuminate\Routing\Router;
use Illuminate\Support\Facades\Config;
use InvalidArgumentException;
Expand Down
1 change: 0 additions & 1 deletion src/JavascriptRenderer.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

use DebugBar\DebugBar;
use DebugBar\JavascriptRenderer as BaseJavascriptRenderer;
use Illuminate\Routing\UrlGenerator;

/**
* {@inheritdoc}
Expand Down
2 changes: 0 additions & 2 deletions src/LaravelDebugbar.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@
use Barryvdh\Debugbar\DataCollector\CacheCollector;
use Barryvdh\Debugbar\DataCollector\EventCollector;
use Barryvdh\Debugbar\DataCollector\FilesCollector;
use Barryvdh\Debugbar\DataCollector\GateCollector;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The same suggestions as above - leave the import and use in the code instead of string values

use Barryvdh\Debugbar\DataCollector\LaravelCollector;
use Barryvdh\Debugbar\DataCollector\LogsCollector;
use Barryvdh\Debugbar\DataCollector\ModelsCollector;
use Barryvdh\Debugbar\DataCollector\MultiAuthCollector;
use Barryvdh\Debugbar\DataCollector\QueryCollector;
use Barryvdh\Debugbar\DataCollector\SessionCollector;
Expand Down
2 changes: 0 additions & 2 deletions src/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace Barryvdh\Debugbar;

use Barryvdh\Debugbar\Middleware\DebugbarEnabled;
use Barryvdh\Debugbar\Middleware\InjectDebugbar;
use DebugBar\DataFormatter\DataFormatter;
use DebugBar\DataFormatter\DataFormatterInterface;
Expand All @@ -12,7 +11,6 @@
use Illuminate\Session\SessionManager;
use Illuminate\Support\Collection;
use Illuminate\View\Engines\EngineResolver;
use Barryvdh\Debugbar\Facade as DebugBar;

class ServiceProvider extends \Illuminate\Support\ServiceProvider
{
Expand Down
1 change: 0 additions & 1 deletion src/Storage/FilesystemStorage.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
namespace Barryvdh\Debugbar\Storage;

use DebugBar\Storage\StorageInterface;
use Illuminate\Filesystem\Filesystem;
use Symfony\Component\Finder\Finder;

/**
Expand Down
1 change: 0 additions & 1 deletion src/Support/Clockwork/ClockworkCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
use DebugBar\DataCollector\DataCollector;
use DebugBar\DataCollector\DataCollectorInterface;
use DebugBar\DataCollector\Renderable;
use Symfony\Component\HttpFoundation\Response;

/**
*
Expand Down
2 changes: 0 additions & 2 deletions src/SymfonyHttpDriver.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
namespace Barryvdh\Debugbar;

use DebugBar\HttpDriverInterface;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Session\Session;

/**
* HTTP driver for Symfony Request/Session
Expand Down