| Conditions | 2 |
| Paths | 2 |
| Total Lines | 13 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 56 | public function checkStatus(): Result |
||
| 57 | { |
||
| 58 | $result = new Result($this->label); |
||
| 59 | $memoryLimitString = ini_get('memory_limit'); |
||
| 60 | $memoryLimit = $this->getMegabytesFromSizeString($memoryLimitString); |
||
| 61 | |||
| 62 | if ($this->memoryRequired > $memoryLimit) { |
||
| 63 | $result->setSuccess(false); |
||
| 64 | $result->setError("Memory required: {$this->memoryRequired}M; limit: {$memoryLimitString}"); |
||
| 65 | } |
||
| 66 | |||
| 67 | return $result; |
||
| 68 | } |
||
| 69 | } |
||
| 70 |