X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FRevision%2FSlotRecord.php;h=7465f790005b7eeeb5808b1d119f878decfd04d7;hb=e65f8ac5110804067366f9f239c13f4f29b66c3d;hp=064f7a47b69d44d1ddda89f65f371ce9f69cf548;hpb=41a744cba7b99e2c6db5d8c97913ed33e1d5c3f6;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/Revision/SlotRecord.php b/includes/Revision/SlotRecord.php index 064f7a47b6..7465f79000 100644 --- a/includes/Revision/SlotRecord.php +++ b/includes/Revision/SlotRecord.php @@ -539,6 +539,11 @@ class SlotRecord { try { $sha1 = $this->getStringField( 'content_sha1' ); } catch ( IncompleteRevisionException $ex ) { + $sha1 = null; + } + + // Compute if missing. Missing could mean null or empty. + if ( $sha1 === null || $sha1 === '' ) { $format = $this->hasField( 'format_name' ) ? $this->getStringField( 'format_name' ) : null;