Migrate to new phan

Bug: T216904
Change-Id: I30864bd3d7f9b9ab674bf6589cd9e5e3aed5bb8d
This commit is contained in:
Kunal Mehta 2019-02-23 21:29:18 -08:00 committed by Daimona Eaytoy
parent 53ab2b5067
commit 577f4dab93
5 changed files with 5 additions and 9 deletions

1
.gitignore vendored
View file

@ -22,4 +22,3 @@ project.index
## Sublime
sublime-*
sftp-config.json
/tests/phan/issues

View file

@ -1,18 +1,18 @@
<?php
$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
$cfg = require __DIR__ . '/../vendor/mediawiki/mediawiki-phan-config/src/config.php';
$cfg['directory_list'] = array_merge(
$cfg['directory_list'],
[
'./../../extensions/CheckUser',
'../../extensions/CheckUser',
]
);
$cfg['exclude_analysis_directory_list'] = array_merge(
$cfg['exclude_analysis_directory_list'],
[
'./../../extensions/CheckUser',
'../../extensions/CheckUser',
]
);

View file

@ -13,7 +13,7 @@
"mediawiki/mediawiki-codesniffer": "24.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
"mediawiki/minus-x": "0.3.2",
"mediawiki/mediawiki-phan-config": "0.3.0"
"mediawiki/mediawiki-phan-config": "0.5.0"
},
"scripts": {
"fix": [

View file

@ -206,9 +206,6 @@ class AbuseFilterVariableHolder {
/**
* Compute all vars which need DB access. Useful for vars which are going to be saved
* cross-wiki or used for offline analysis.
*
* @suppress PhanUndeclaredProperty for $value->mMethod (phan thinks $value is always AFPData)
* @suppress PhanUndeclaredMethod for $value->compute (phan thinks $value is always AFPData)
*/
public function computeDBVars() {
static $dbTypes = [

View file

@ -195,7 +195,7 @@ class AbuseFilterViewTestBatch extends AbuseFilterView {
if ( $result || $this->mShowNegative ) {
// Stash result in RC item
$rc = RecentChange::newFromRow( $row );
/** @suppress PhanUndeclaredProperty for $rc->filterResult, which isn't a big deal */
// @phan-suppress-next-line PhanUndeclaredProperty not a big deal
$rc->filterResult = $result;
$rc->counter = $counter++;
$output .= $changesList->recentChangesLine( $rc, false );