X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FTitle.php;h=038e8b1b20288cf60a6feace353aaf60350d3311;hb=d6016fa1f985120829cfeb596571dd844da8b4e3;hp=5b0c3bc2dd48b43471ca17675560acc13f25132a;hpb=ef44b9075c0e2746ec2df0aaefa0ae9b9174d2fa;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/Title.php b/includes/Title.php index 5b0c3bc2dd..038e8b1b20 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -2447,7 +2447,7 @@ class Title implements LinkTarget { # XXX: this might be better using restrictions if ( $action === 'patrol' ) { - return []; + return $errors; } if ( preg_match( '/^' . preg_quote( $user->getName(), '/' ) . '\//', $this->mTextform ) ) { @@ -4438,7 +4438,7 @@ class Title implements LinkTarget { * Get the oldest revision timestamp of this page * * @param int $flags Title::GAID_FOR_UPDATE - * @return string MW timestamp + * @return string|null MW timestamp */ public function getEarliestRevTime( $flags = 0 ) { $rev = $this->getFirstRevision( $flags ); @@ -4846,8 +4846,9 @@ class Title implements LinkTarget { $dbw = wfGetDB( DB_MASTER ); $dbw->onTransactionPreCommitOrIdle( - function () { - ResourceLoaderWikiModule::invalidateModuleCache( $this, null, null, wfWikiID() ); + function () use ( $dbw ) { + ResourceLoaderWikiModule::invalidateModuleCache( + $this, null, null, $dbw->getDomainId() ); }, __METHOD__ );