Wikimedia

Add/Remove/Notify of Publishers should happen in bulk with $userIds in Newsletter extension

This task is about MediaWiki's Newsletter extension.

https://github.com/wikimedia/mediawiki-extensions-Newsletter/blob/master/includes/NewsletterDb.php#L95 should accept UserIdList just like addSubscription above. Same for RemovePublishers.

Possibly affected code would be:

https://github.com/wikimedia/mediawiki-extensions-Newsletter/blob/master/includes/NewsletterEditPage.php#L415 -- here we should directly call our addSubscription with the whole list of users instead. Below that, the notifyPublishers() should also take a userIdList and this should happen in the next line. https://github.com/wikimedia/mediawiki-extensions-Newsletter/blob/master/includes/content/NewsletterDataUpdate.php#L126 -- same here. Probably the removePublishers() too.

Difficulty: Moderately tough, but easy once you read the examples given above.

You are expected to provide a patch in Wikimedia Gerrit. See https://www.mediawiki.org/wiki/Gerrit/Tutorial for how to set up Git and Gerrit.

Task tags

  • php
  • newsletter
  • improvement

Students who completed this task

pppery

Task type

  • code Code
close

2017