Page MenuHomePhabricator

Update move permission code
Closed, ResolvedPublic


Per @Legoktm:

  • AbortMove has been removed completely.
  • MovePageIsValidMove should only be used for technical restrictions. NS_TOPIC qualifies here.
  • However, for permissions issues (is the destination namespace Flow and if not do they have flow-create-board), we should use MovePageCheckPermissions.

While we're at this, document these hooks on-wiki (it's currently only in docs/hooks.txt)


Related Gerrit Patches:
mediawiki/extensions/Flow : masterBetter error handling and hook use for moves

Event Timeline

Mattflaschen-WMF raised the priority of this task from to Needs Triage.
Mattflaschen-WMF updated the task description. (Show Details)
Restricted Application added subscribers: StudiesWorld, Aklapper. · View Herald TranscriptFeb 9 2016, 10:37 PM

Change 273414 had a related patch set uploaded (by Mattflaschen):
Better error handling and hook use for moves

Change 273414 merged by jenkins-bot:
Better error handling and hook use for moves

Checked in betalabs as part of verifying T127785: Board moves in Flow not working and T127693: Flow board move requiring allowCreation fails on zh.wp.

  • a user without Flow bot rights can move non-Flow pages
  • a user with Flow bot rights can move Flow pages and non-Flow pages
  • protected pages and subpages also were checked

Additionaly checked on cawiki which has Flow enabled namespaces, e.g. Flow test talk and Viquipèdia Discussió.

A user who with the 'Move' option available (e.g. Autoconfirmed) can move Flow board to the Flow enabled namespaces.

Also checked the following combinations when moving to Flow enabled namespaces:

  • wikitext page to Flow enabled namespace
  • Flow enabled page to non-Flow enabled namespace

In all cases the structure of the page is preserved - wikitext remains wikitext, and Flow enabled page is still a Flow page.

jmatazzoni closed this task as Resolved.Mar 3 2016, 7:20 PM