HomePhabricator

Fix actor migration scripts

Description

Fix actor migration scripts

  • Lookup for user_id instead of user_name, since user renames can cause old user names with no matching actor, as was the case for r_user_name field from user_relationship table at least. This may break for anonymous users (that will have user_id = 0). However, the functionality of this extension isn't mean to be used for anons, apparently.
  • Do not instance a new user object. Instead, create one from the corresponding ID. Otherwise it creates users with a user name but user id equal to 0, causing getActorId to fail.
  • Use DISTINCT to do the update once for each user id.

Bug: T251707
Change-Id: I919df512003565c767c12c9b40606b1a02313abc

Details

Provenance
Ciencia_Al_PoderAuthored on May 3 2020, 8:43 PM
Parents
rESPRd023f5e25a3c: Merge "Fix up namespacing"
Branches
Unknown
Tags
Unknown
ChangeId
I919df512003565c767c12c9b40606b1a02313abc