Conditions | 2 |
Paths | 2 |
Total Lines | 12 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
19 | 3 | public function __invoke(Quote $quote): bool |
|
20 | { |
||
21 | 3 | if (null === $quote->getSymbol()) { |
|
22 | 2 | return false; |
|
23 | } |
||
24 | |||
25 | 2 | $current = $this->findLatestDateTimeFromNews($quote); |
|
26 | 2 | $previous = self::$cacheOldestBySymbol[$quote->getSymbol()] ?? ''; |
|
27 | |||
28 | 2 | self::$cacheOldestBySymbol[$quote->getSymbol()] = $current; |
|
29 | |||
30 | 2 | return $current > $previous; |
|
31 | } |
||
51 |