* @param string &$oldimage Archive name
* @param string $reason Reason of the deletion
* @param bool $suppress Whether to mark all deleted versions as restricted
- * @param User $user User object performing the request
+ * @param User|null $user User object performing the request
* @param array $tags Tags to apply to the deletion action
* @throws MWException
* @return Status
$logEntry->setTags( $tags );
$logid = $logEntry->insert();
$dbw->onTransactionPreCommitOrIdle(
- function () use ( $dbw, $logEntry, $logid ) {
+ function () use ( $logEntry, $logid ) {
$logEntry->publish( $logid );
},
__METHOD__