Conditions | 3 |
Paths | 2 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
14 | public function check(Result $result): bool |
||
15 | { |
||
16 | $check = false; |
||
17 | if ($result->getFirstTeamUserResult() !== null && $result->getSecondTeamUserResult() !== null) { |
||
18 | $diffUserResult = $result->getFirstTeamUserResult() - $result->getSecondTeamUserResult(); |
||
19 | $diffGameResult = $result->getFirstTeamResult() - $result->getSecondTeamResult(); |
||
20 | $check = ($diffGameResult === $diffUserResult); |
||
21 | } |
||
22 | |||
23 | return $check; |
||
24 | } |
||
32 | } |