protected function ban(Request $request, Carbon $expirationDate)
    {
        $params = [
            'ip'           => $request->getClientIp(),
            '--reason'     => 'Too many attempts.',
            '--canBanSelf' => true,
            '--expire'     => $expirationDate->toDateString(),
        ];

        $this->kernel->call('ban-management:add-rule', $params);
    }
protected function ban(Request $request, Carbon $expirationDate)
    {
        $params = [
            'ip'           => $request->getClientIp(),
            '--reason'     => 'Too many attempts.',
            '--canBanSelf' => true,
            '--expire'     => $expirationDate->toDateString(),
        ];

        $this->kernel->call('ban-management:add-rule', $params);
    }
protected function ban ( Request $ request , Carbon $ expirationDate ) { $ params = [ 'ip' => $ request -> getClientIp ( ) , '--reason' => 'Too many attempts.' , '--canBanSelf' => true , '--expire' => $ expirationDate -> toDateString ( ) , ] ; $ this -> kernel -> call ( 'ban-management:add-rule' , $ params ) ; }
Ban the given request.

@param Request $request
@param Carbon $expirationDate
Ban the given request .