Differential - tighten up access of Differential data from other applications
Summary: Fixes T6790. Turn the old method into "new" (old signature) and "newEphemeral". Deploy "newEphemeral" as many places as possible; basically places we are not in the Differential application *and* have no intentions of ever saving the diff. These callsites are also all places we are just trying to get some changesets at the end of the day. Test Plan: set differential application policy to 'administrators only'. viewed a commit in diffusion and it worked without any errors! i'm just using my thinkin' noodle on the other code paths. Reviewers: epriestley Reviewed By: epriestley Subscribers: Korvin, epriestley Maniphest Tasks: T6790 Differential Revision: https://secure.phabricator.com/D11020
This commit is contained in:
@@ -163,8 +163,7 @@ final class PhabricatorDifferenceEngine {
|
||||
$diff = $this->generateRawDiffFromFileContent($old, $new);
|
||||
|
||||
$changes = id(new ArcanistDiffParser())->parseDiff($diff);
|
||||
$diff = DifferentialDiff::newFromRawChanges(
|
||||
PhabricatorUser::getOmnipotentUser(),
|
||||
$diff = DifferentialDiff::newEphemeralFromRawChanges(
|
||||
$changes);
|
||||
return head($diff->getChangesets());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user