Index: trunk/phase3/includes/Title.php |
— | — | @@ -1272,12 +1272,12 @@ |
1273 | 1273 | } |
1274 | 1274 | // Check getUserPermissionsErrors hook |
1275 | 1275 | if ( !wfRunHooks( 'getUserPermissionsErrors', array( &$this, &$user, $action, &$result ) ) ) { |
1276 | | - $errors[] = $this->resultToError( $errors, $result ); |
| 1276 | + $errors = $this->resultToError( $errors, $result ); |
1277 | 1277 | } |
1278 | 1278 | // Check getUserPermissionsErrorsExpensive hook |
1279 | 1279 | if ( $doExpensiveQueries && !( $short && count( $errors ) > 0 ) && |
1280 | 1280 | !wfRunHooks( 'getUserPermissionsErrorsExpensive', array( &$this, &$user, $action, &$result ) ) ) { |
1281 | | - $errors[] = $this->resultToError( $errors, $result ); |
| 1281 | + $errors = $this->resultToError( $errors, $result ); |
1282 | 1282 | } |
1283 | 1283 | |
1284 | 1284 | return $errors; |