]> BookStack Code Mirror - bookstack/blobdiff - app/Http/Middleware/Authenticate.php
Fixed local_secure_restricted preventing attachment uploads
[bookstack] / app / Http / Middleware / Authenticate.php
index c9b2726e8c4eca4f9148f7567a035433bf216879..a320291122b6f632b0bc36a8e96d15e42472a5f8 100644 (file)
@@ -3,46 +3,21 @@
 namespace BookStack\Http\Middleware;
 
 use Closure;
-use Illuminate\Contracts\Auth\Guard;
+use Illuminate\Http\Request;
 
 class Authenticate
 {
-    /**
-     * The Guard implementation.
-     * @var Guard
-     */
-    protected $auth;
-
-    /**
-     * Create a new filter instance.
-     * @param  Guard $auth
-     */
-    public function __construct(Guard $auth)
-    {
-        $this->auth = $auth;
-    }
-
     /**
      * Handle an incoming request.
-     * @param  \Illuminate\Http\Request  $request
-     * @param  \Closure  $next
-     * @return mixed
      */
-    public function handle($request, Closure $next)
+    public function handle(Request $request, Closure $next)
     {
-        if ($this->auth->check()) {
-            $requireConfirmation = (setting('registration-confirmation') || setting('registration-restrict'));
-   &n