MediaWiki
master
|
Job to fix double redirects after moving a page. More...
Public Member Functions | |
__construct ($title, $params=false, $id=0) | |
getUser () | |
Get a user object for doing edits, from a request-lifetime cache. | |
run () | |
Static Public Member Functions | |
static | fixRedirects ($reason, $redirTitle, $destTitle=false) |
Insert jobs into the job queue to fix redirects to the given title. | |
static | getFinalDestination ($title) |
Get the final destination of a redirect. | |
Public Attributes | |
$reason | |
$redirTitle | |
Static Public Attributes | |
static | $user |
Job to fix double redirects after moving a page.
Definition at line 29 of file DoubleRedirectJob.php.
DoubleRedirectJob::__construct | ( | $ | title, |
$ | params = false , |
||
$ | id = 0 |
||
) |
Definition at line 76 of file DoubleRedirectJob.php.
References Job\$id, Job\$params, Job\$title, and Title\newFromText().
static DoubleRedirectJob::fixRedirects | ( | $ | reason, |
$ | redirTitle, | ||
$ | destTitle = false |
||
) | [static] |
Insert jobs into the job queue to fix redirects to the given title.
$reason | String: the reason for the fix, see message "double-redirect-fixed-<reason>" |
$redirTitle | Title: the title which has changed, redirects pointing to this title are fixed |
$destTitle | bool Not used |
Definition at line 43 of file DoubleRedirectJob.php.
References $reason, $redirTitle, $res, Job\$title, array(), as, Job\batchInsert(), Title\makeTitle(), and wfGetDB().
Referenced by MovePageForm\doSubmit().
static DoubleRedirectJob::getFinalDestination | ( | $ | title | ) | [static] |
Get the final destination of a redirect.
$title | Title |
Definition at line 155 of file DoubleRedirectJob.php.
References Job\$title, array(), check, Title\getDBkey(), Title\getInterwiki(), Title\getNamespace(), Title\getPrefixedDBkey(), Title\makeTitle(), redirect, wfDebug(), and wfGetDB().
Referenced by run().
Get a user object for doing edits, from a request-lifetime cache.
Definition at line 199 of file DoubleRedirectJob.php.
References $user, $user, User\newFromName(), text, and wfMessage().
Referenced by run().
Reimplemented from Job.
Definition at line 85 of file DoubleRedirectJob.php.
References $article, $reason, $wgUser, Job\factory(), MagicWord\get(), getFinalDestination(), getUser(), global, Title\makeTitle(), Revision\newFromTitle(), IDBAccessObject\READ_LATEST, Job\setLastError(), title, wfDebug(), and wfMessage().
DoubleRedirectJob::$reason |
Definition at line 30 of file DoubleRedirectJob.php.
Referenced by fixRedirects(), and run().
DoubleRedirectJob::$redirTitle |
Definition at line 30 of file DoubleRedirectJob.php.
Referenced by fixRedirects().
DoubleRedirectJob::$user [static] |
Definition at line 35 of file DoubleRedirectJob.php.
Referenced by getUser().