Skip to content

Commit bd490fe

Browse files
committed
formatting
1 parent 0bc4977 commit bd490fe

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/Illuminate/Redis/Limiters/DurationLimiter.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public function acquire()
119119
public function tooManyAttempts()
120120
{
121121
[$this->decaysAt, $this->remaining] = $this->redis->eval(
122-
$this->tooManyAttemptsScript(), 1, $this->name, microtime(true), time(), $this->decay, $this->maxLocks
122+
$this->tooManyAttemptsLuaScript(), 1, $this->name, microtime(true), time(), $this->decay, $this->maxLocks
123123
);
124124

125125
return $this->remaining <= 0;
@@ -181,7 +181,7 @@ protected function luaScript()
181181
*
182182
* @return string
183183
*/
184-
protected function tooManyAttemptsScript()
184+
protected function tooManyAttemptsLuaScript()
185185
{
186186
return <<<'LUA'
187187

tests/Integration/Queue/ThrottlesExceptionsWithRedisTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ public function handle()
140140

141141
public function middleware()
142142
{
143-
return [new ThrottlesExceptionsWithRedis(2, 10, 0, $this->key)];
143+
return [(new ThrottlesExceptionsWithRedis(2, 10))->by($this->key)];
144144
}
145145
}
146146

@@ -162,6 +162,6 @@ public function handle()
162162

163163
public function middleware()
164164
{
165-
return [new ThrottlesExceptionsWithRedis(2, 10, 0, $this->key)];
165+
return [(new ThrottlesExceptionsWithRedis(2, 10))->by($this->key)];
166166
}
167167
}

0 commit comments

Comments
 (0)