Conditions | 5 |
Paths | 4 |
Total Lines | 18 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
65 | public function addAnnotation( |
||
66 | DIProperty $property, SemanticData $semanticData |
||
67 | ) { |
||
68 | if ( $this->approvedStatus === null && class_exists( 'ApprovedRevs' ) ) { |
||
69 | $logReader = $this->appFactory->newDatabaseLogReader( |
||
70 | $semanticData->getSubject()->getTitle(), 'approval' |
||
71 | ); |
||
72 | $this->approvedStatus = $logReader->getStatusOfLogEntry(); |
||
73 | } |
||
74 | |||
75 | if ( is_string( $this->approvedStatus ) && $this->approvedStatus !== "" ) { |
||
76 | $semanticData->addPropertyObjectValue( |
||
77 | $property, $this->getDataItem() |
||
78 | ); |
||
79 | } else { |
||
80 | $semanticData->removeProperty( $property ); |
||
81 | } |
||
82 | } |
||
83 | } |
||
84 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..