mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-23 05:50:55 +01:00
Fix an exception with user cache generation in "bin/conduit call --as <user>"
Summary: Ref T13249. Using "--as" to call some Conduit methods as a user can currently fatal when trying to access settings/preferences. Allow inline regeneration of user caches. Test Plan: Called `project.edit` to add a member. Before: constructing a policy field tried to access the user's preferences and failed. After: Smooth sailing. Reviewers: amckinley Reviewed By: amckinley Maniphest Tasks: T13249 Differential Revision: https://secure.phabricator.com/D20255
This commit is contained in:
parent
a3ebaac0f0
commit
9918ea1fb7
1 changed files with 4 additions and 0 deletions
|
@ -58,6 +58,10 @@ final class PhabricatorConduitCallManagementWorkflow
|
|||
'No such user "%s" exists.',
|
||||
$as));
|
||||
}
|
||||
|
||||
// Allow inline generation of user caches for the user we're acting
|
||||
// as, since some calls may read user preferences.
|
||||
$actor->setAllowInlineCacheGeneration(true);
|
||||
} else {
|
||||
$actor = $viewer;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue