Page MenuHomePhabricator

Enable Special:NovaSecurityGroup again in MediaWiki:Common.js
Closed, DeclinedPublic

Description

As part of T142165, @yuvipanda disabled https://wikitech.wikimedia.org/wiki/Special:NovaInstance and https://wikitech.wikimedia.org/wiki/Special:NovaSecurityGroup, latter enabling the former again. AFAIUI, T142165 has been completely resolved and https://wikitech.wikimedia.org/wiki/Special:NovaSecurityGroup can be enabled again as well.

So:

// For https://phabricator.wikimedia.org/T142165
$(function() {
	function disableSecurityGroups() {
		$('a[href="/wiki/Special:NovaSecurityGroup"]').click(function() { alert("Security Group creation disabled temporarily, see https://phabricator.wikimedia.org/T142165 for details"); return false; });
		if (mw.config.get('wgPageName') === 'Special:NovaSecurityGroup' ) {
			$('#content').html('<h3>Security group manipulation temporarily disabled, see <a href="https://phabricator.wikimedia.org/T142165">link for details</a></h3>');
		}
	}

	function disableInstanceCreation() {
		//$('a[href="/wiki/Special:NovaInstance"]').click(function() { alert("Instance creation disabled temporarily, see link for details"); return false; });
		if (mw.config.get('wgPageName') === 'Special:NovaInstance' ) {
			$('#mw-content-text h3 span a[title="Special:NovaInstance"]').html('New instance creation disabled').attr('href', 'https://phabricator.wikimedia.org/T142165');
		}
	}

	disableSecurityGroups();
});

should be removed from https://wikitech.wikimedia.org/wiki/MediaWiki:Common.js. (NB: I recommend Horizon for managing security groups; this task is just about removing bit rot, not making a statement.)

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

@Andrew is there any reason not to remove this javascript band-aid?

It should be fine to remove the hack, although it might be even better to remove the security group functionality from wikitech entirely.

Reedy subscribed.

SpecialPage is going away