dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "Return null from EditPage::importContentFormData"
[lhc/web/wiklou.git]
/
maintenance
/
deduplicateArchiveRevId.php
diff --git
a/maintenance/deduplicateArchiveRevId.php
b/maintenance/deduplicateArchiveRevId.php
index
2442caa
..
a1d4e99
100644
(file)
--- a/
maintenance/deduplicateArchiveRevId.php
+++ b/
maintenance/deduplicateArchiveRevId.php
@@
-33,8
+33,13
@@
class DeduplicateArchiveRevId extends LoggedUpdateMaintenance {
protected function doDBUpdates() {
$this->output( "Deduplicating ar_rev_id...\n" );
protected function doDBUpdates() {
$this->output( "Deduplicating ar_rev_id...\n" );
-
$dbw = $this->getDB( DB_MASTER );
$dbw = $this->getDB( DB_MASTER );
+ // Sanity check. If this is a new install, we don't need to do anything here.
+ if ( PopulateArchiveRevId::isNewInstall( $dbw ) ) {
+ $this->output( "New install, nothing to do here.\n" );
+ return true;
+ }
+
PopulateArchiveRevId::checkMysqlAutoIncrementBug( $dbw );
$minId = $dbw->selectField( 'archive', 'MIN(ar_rev_id)', [], __METHOD__ );
PopulateArchiveRevId::checkMysqlAutoIncrementBug( $dbw );
$minId = $dbw->selectField( 'archive', 'MIN(ar_rev_id)', [], __METHOD__ );