SlotRecord:compute sha1 if empty.
authordaniel <dkinzler@wikimedia.org>
Thu, 4 Jul 2019 08:52:55 +0000 (10:52 +0200)
committerDaniel Kinzler <dkinzler@wikimedia.org>
Thu, 4 Jul 2019 08:57:17 +0000 (08:57 +0000)
commit440d9b84beef50eaefd209fc371ce315a242c923
treec8021f3cd11402404d3c4639e317c6645bcc5eb5
parent8bc855d71ff995f4c055de9cfec6d7b2c8821ee4
SlotRecord:compute sha1 if empty.

The SHA1 should be computed automatically if empty, not just if it is
missing entirely. This is needed since rev_sha1 may contain an empty
string for old revisions.

Bug: T200653
Bug: T219816
Change-Id: Ia6870a828bc9661fb05085e36315a86483ec48c4
includes/Revision/SlotRecord.php
tests/phpunit/includes/Revision/SlotRecordTest.php