| @@ 38-53 (lines=16) @@ | ||
| 35 | } |
|
| 36 | } |
|
| 37 | ||
| 38 | private function warnForUnusedVariables(Hydrator $processor): void |
|
| 39 | { |
|
| 40 | $unusedVariables = $processor->getUnusedVariables(); |
|
| 41 | ||
| 42 | if(! empty($unusedVariables)) |
|
| 43 | { |
|
| 44 | $logger = $this->app['logger']; |
|
| 45 | ||
| 46 | $logger->warning('You have unused variables : you should remove them or check if you have not mispelled them'); |
|
| 47 | ||
| 48 | $logger->warning(sprintf( |
|
| 49 | 'Unused variables : %s', |
|
| 50 | implode(', ', $unusedVariables) |
|
| 51 | )); |
|
| 52 | } |
|
| 53 | } |
|
| 54 | ||
| 55 | private function warnForUnvaluedVariables(Hydrator $processor): void |
|
| 56 | { |
|
| @@ 55-68 (lines=14) @@ | ||
| 52 | } |
|
| 53 | } |
|
| 54 | ||
| 55 | private function warnForUnvaluedVariables(Hydrator $processor): void |
|
| 56 | { |
|
| 57 | $unvaluedVariables = $processor->getUnvaluedVariables(); |
|
| 58 | ||
| 59 | if(! empty($unvaluedVariables)) |
|
| 60 | { |
|
| 61 | $logger = $this->app['logger']; |
|
| 62 | ||
| 63 | $logger->warning(sprintf( |
|
| 64 | 'Missing values for variables : %s (TODO markers found)', |
|
| 65 | implode(', ', $unvaluedVariables) |
|
| 66 | )); |
|
| 67 | } |
|
| 68 | } |
|
| 69 | } |
|
| 70 | ||