*
* @file
*/
+use MediaWiki\ChangeTags\Taggable;
/**
* Utility class for creating new RC entries
* we're having to include both rc_comment and rc_comment_text/rc_comment_data
* so random crap works right.
*/
-class RecentChange {
+class RecentChange implements Taggable {
// Constants for the rc_source field. Extensions may also have
// their own source constants.
const SRC_EDIT = 'mw.edit';
global $wgActorTableSchemaMigrationStage;
wfDeprecated( __METHOD__, '1.31' );
- if ( $wgActorTableSchemaMigrationStage > MIGRATION_WRITE_BOTH ) {
+ if ( $wgActorTableSchemaMigrationStage & SCHEMA_COMPAT_READ_NEW ) {
// If code is using this instead of self::getQueryInfo(), there's a
// decent chance it's going to try to directly access
// $row->rc_user or $row->rc_user_text and we can't give it
- // useful values here once those aren't being written anymore.
+ // useful values here once those aren't being used anymore.
throw new BadMethodCallException(
- 'Cannot use ' . __METHOD__ . ' when $wgActorTableSchemaMigrationStage > MIGRATION_WRITE_BOTH'
+ 'Cannot use ' . __METHOD__
+ . ' when $wgActorTableSchemaMigrationStage has SCHEMA_COMPAT_READ_NEW'
);
}
*
* @since 1.28
*
- * @param string|array $tags
+ * @param string|string[] $tags
*/
public function addTags( $tags ) {
if ( is_string( $tags ) ) {