Conditions | 3 |
Paths | 3 |
Total Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
37 | public function sequence(int $currentTime) |
||
38 | { |
||
39 | $store = $this->cache->getStore(); |
||
40 | |||
41 | if ($store instanceof \Illuminate\Cache\RedisStore) { |
||
42 | $lua = "return redis.call('exists',KEYS[1])<1 and redis.call('psetex',KEYS[1],ARGV[2],ARGV[1])"; |
||
43 | if ($store->connection()->eval($lua, 1, $key = $srore->getPrefix().$currentTime, 1, 1)) { |
||
44 | return $store->connection()->incrby($key, 1); |
||
45 | } |
||
46 | } |
||
47 | |||
48 | return (new RandomSequenceResolver())->sequence($currentTime); |
||
49 | } |
||
50 | } |
||
51 |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.