| Conditions | 3 |
| Paths | 3 |
| Total Lines | 12 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 9 |
| CRAP Score | 3 |
| Changes | 2 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 38 | 4 | public function getPropertyForId( PropertyId $propertyId ) { |
|
| 39 | 4 | $property = $this->entityCache->fetch( $propertyId ); |
|
| 40 | |||
| 41 | 4 | if( $property === null ) { |
|
| 42 | 3 | $property = $this->propertyLookup->getPropertyForId( $propertyId ); |
|
| 43 | 3 | if( $property !== null ) { |
|
| 44 | 2 | $this->entityCache->save( $property ); |
|
| 45 | 2 | } |
|
| 46 | 3 | } |
|
| 47 | |||
| 48 | 4 | return $property; |
|
| 49 | } |
||
| 50 | } |
||
| 51 |