<?php
/**
- * Created on Jun 25, 2013
- *
- * Copyright © 2013 Brad Jorsch <bjorsch@wikimedia.org>
+ * Copyright © 2013 Wikimedia Foundation and contributors
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
}
// Check if user can add tags
- if ( count( $params['tags'] ) ) {
+ if ( $params['tags'] ) {
$ableToTag = ChangeTags::canAddTagsAccompanyingChange( $params['tags'], $user );
if ( !$ableToTag->isOK() ) {
$this->dieStatus( $ableToTag );
}
$list->reloadFromMaster();
- // @codingStandardsIgnoreStart Avoid function calls in a FOR loop test part
+ // phpcs:ignore Generic.CodeAnalysis.ForLoopWithTestFunctionCall
for ( $item = $list->reset(); $list->current(); $item = $list->next() ) {
$data['items'][$item->getId()] += $item->getApiData( $this->getResult() );
}
- // @codingStandardsIgnoreEnd
$data['items'] = array_values( $data['items'] );
ApiResult::setIndexedTagName( $data['items'], 'i' );
}
public function getHelpUrls() {
- return 'https://www.mediawiki.org/wiki/API:Revisiondelete';
+ return 'https://www.mediawiki.org/wiki/Special:MyLanguage/API:Revisiondelete';
}
}