datatable.directory codebase
https://datatable.directory/
20 lines
410 B
20 lines
410 B
7 years ago
|
<?php
|
||
|
|
||
|
|
||
|
namespace App\Http\Middleware;
|
||
|
|
||
|
|
||
|
use Illuminate\Routing\Middleware\ThrottleRequests;
|
||
|
|
||
|
class ThrottleIfNotDebug extends ThrottleRequests
|
||
|
{
|
||
|
public function handle($request, \Closure $next, $maxAttempts = 60, $decayMinutes = 1)
|
||
|
{
|
||
|
if (config('app.debug')) {
|
||
|
return $next($request);
|
||
|
}
|
||
|
|
||
|
return parent::handle($request, $next, $maxAttempts, $decayMinutes);
|
||
|
}
|
||
|
}
|