WikiPage: Allow replaceSection on an nonexistent page
authorAdam Roses Wight <awight@wikimedia.org>
Thu, 5 Jun 2014 00:34:42 +0000 (17:34 -0700)
committerTheDJ <hartman.wiki@gmail.com>
Thu, 5 Jun 2014 20:31:17 +0000 (20:31 +0000)
commit69bf90f2bce761b787d99673fb10456347f35f81
tree7ae92087ffd969445df1fc29ada3686b3736fa81
parent94cbdf34f6699d07d8ed436fa86845715e8ea732
WikiPage: Allow replaceSection on an nonexistent page

This corrects a regression, where replaceSection would require that the
page have at least one revision in the database.  If the page does not
exist, continue with the replacement, using a null baseRevId.

Also: clean up a few comments in the replaceSection functions.

Bug: 66141
Change-Id: Ieb2cb05aee07a1d8bbdc3bdfe9536dfa8bee529e
includes/WikiPage.php