Diffs: avoid getContentHandler on null error
Bug: T388708 Change-Id: I4dbbeb70a53c6ca0b3c44995d13e2c5de097ddf2 (cherry picked from commit 7aee965efdbe316f8ea13b1d03b4c1afab11d255)
This commit is contained in:
parent
810a248988
commit
65d32263fd
1 changed files with 4 additions and 0 deletions
|
|
@ -319,6 +319,10 @@ class DifferenceEngine extends ContextSource {
|
|||
// Do not produce a diff of identical content
|
||||
continue;
|
||||
}
|
||||
if ( !$contents['new'] && !$contents['old'] ) {
|
||||
// Nothing to diff (i.e both revisions are corrupted), just ignore
|
||||
continue;
|
||||
}
|
||||
$handler = ( $contents['new'] ?: $contents['old'] )->getContentHandler();
|
||||
$this->slotDiffRenderers[$role] = $handler->getSlotDiffRenderer(
|
||||
$this->getContext(),
|
||||
|
|
|
|||
Loading…
Reference in a new issue