ok

Mini Shell

Direktori : /home2/selectio/www/innerstore/vendor/barryvdh/laravel-debugbar/src/Controllers/
Upload File :
Current File : /home2/selectio/www/innerstore/vendor/barryvdh/laravel-debugbar/src/Controllers/BaseController.php

<?php

namespace Barryvdh\Debugbar\Controllers;

use Barryvdh\Debugbar\LaravelDebugbar;
use Illuminate\Routing\Controller;
use Illuminate\Http\Request;
use Laravel\Telescope\Telescope;

// phpcs:ignoreFile
if (class_exists('Illuminate\Routing\Controller')) {

    class BaseController extends Controller
    {
        protected $debugbar;

        public function __construct(Request $request, LaravelDebugbar $debugbar)
        {
            $this->debugbar = $debugbar;

            if ($request->hasSession()) {
                $request->session()->reflash();
            }

            $this->middleware(function ($request, $next) {
                if (class_exists(Telescope::class)) {
                    Telescope::stopRecording();
                }
                return $next($request);
            });
        }
    }

} else {

    class BaseController
    {
        protected $debugbar;

        public function __construct(Request $request, LaravelDebugbar $debugbar)
        {
            $this->debugbar = $debugbar;

            if ($request->hasSession()) {
                $request->session()->reflash();
            }
        }
    }
}

Zerion Mini Shell 1.0