From de1fa0ef272851b7be00e4f78b1cdb44777363db Mon Sep 17 00:00:00 2001 From: Jack Phoenix Date: Wed, 10 Jul 2024 07:40:34 +0000 Subject: [PATCH] Revert "LoadExtensionSchemaUpdates: Remove unused path from 'runMaintenance' action" This reverts commit bab4d432067b58c38b180e4c35796e6a3d6c2bb9. Reason for revert: breaks stated, advertised LTS compatibility that end-users expect (see https://www.mediawiki.org/wiki/Social_tools/MediaWiki_compatibility) (well, technically AJAXPoll isn't really a social tool per se, but some listings include it anyway, so...) Change-Id: Ib0c4bde7040cdbb893acb200aa053fb1280078ff --- extension.json | 2 +- includes/AJAXPoll.php | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/extension.json b/extension.json index 51fb23b..ac6e6a5 100644 --- a/extension.json +++ b/extension.json @@ -11,7 +11,7 @@ "type": "parserhook", "license-name": "GFDL-1.2", "requires": { - "MediaWiki": ">= 1.43" + "MediaWiki": ">= 1.35.3" }, "GroupPermissions": { "*": { diff --git a/includes/AJAXPoll.php b/includes/AJAXPoll.php index 44dd986..ab9ad80 100644 --- a/includes/AJAXPoll.php +++ b/includes/AJAXPoll.php @@ -664,9 +664,14 @@ During the last 48 hours, {$tab2->votes} votes have been given."; // adding a new, UNIQUE INDEX on a new AUTO_INCREMENT field (which the // script also creates) and, of course, finally the new column is populated // with data. + // PITFALL WARNING! Do NOT change this to $updater->runMaintenance, + // THEY ARE NOT THE SAME THING and this MUST be using addExtensionUpdate + // instead for the code to work as desired! + // HT Skizzerz $updater->addExtensionUpdate( [ 'runMaintenance', 'MigrateOldAJAXPollUserColumnsToActor', + '../maintenance/migrateOldAJAXPollUserColumnsToActor.php' ] ); // 3) drop the now unused column