Index: trunk/extensions/AbuseFilter/AbuseFilter.class.php |
— | — | @@ -1003,7 +1003,15 @@ |
1004 | 1004 | $vars = array(); |
1005 | 1005 | $title = Title::makeTitle( $row->rc_namespace, $row->rc_title ); |
1006 | 1006 | |
1007 | | - $vars = array_merge( $vars, self::generateUserVars( User::newFromId( $row->rc_user ) ) ); |
| 1007 | + if ($row->rc_user) |
| 1008 | + $user = User::newFromId( $row->rc_user ); |
| 1009 | + else { |
| 1010 | + $user = new User; |
| 1011 | + $user->setName( $row->rc_user_text ); |
| 1012 | + } |
| 1013 | + |
| 1014 | + $vars = array_merge( $vars, self::generateUserVars( $user ) ); |
| 1015 | + |
1008 | 1016 | $vars = array_merge( $vars, self::generateTitleVars( $title, 'ARTICLE' ) ); |
1009 | 1017 | $vars['ACTION'] = 'edit'; |
1010 | 1018 | $vars['SUMMARY'] = $row->rc_comment; |
— | — | @@ -1027,7 +1035,13 @@ |
1028 | 1036 | public static function getMoveVarsFromRCRow( $row ) { |
1029 | 1037 | $vars = array(); |
1030 | 1038 | |
1031 | | - $user = User::newFromId( $row->rc_user ); |
| 1039 | + if ($row->rc_user) |
| 1040 | + $user = User::newFromId( $row->rc_user ); |
| 1041 | + else { |
| 1042 | + $user = new User; |
| 1043 | + $user->setName( $row->rc_user_text ); |
| 1044 | + } |
| 1045 | + |
1032 | 1046 | $oldTitle = Title::makeTitle( $row->rc_namespace, $row->rc_title ); |
1033 | 1047 | $newTitle = Title::newFromText( trim($row->rc_params) ); |
1034 | 1048 | |