$logid = $logEntry->insert();
$dbw->onTransactionPreCommitOrIdle(
- function () use ( $dbw, $logEntry, $logid ) {
+ function () use ( $logEntry, $logid ) {
// T58776: avoid deadlocks (especially from FileDeleteForm)
$logEntry->publish( $logid );
},
}
// raise error, when the edit is an edit without a new version
- $statusRev = isset( $status->value['revision'] )
- ? $status->value['revision']
- : null;
+ $statusRev = $status->value['revision'] ?? null;
if ( !( $statusRev instanceof Revision ) ) {
$resultDetails = [ 'current' => $current ];
return [ [ 'alreadyrolled',