@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Require commit identities when editing commits to resolve an issue with audit actions not applying properly

Summary:
See <https://discourse.phabricator-community.org/t/cannot-audit-a-git-commit/2848>. In D20581, I made some audit behavior dependent upon identities, but the actual edit flow doesn't load them. This can cause us to raise an "attach identities first" exception in the bowels of the edit workflow and trigger unexpected behavior at top level.

Load identities when editing a commit so that the transaction flows have access to identity information and can use it to figure out if a user is an author, etc.

Test Plan:
- As an auditor, applied an "Accept Commit" action to an open audit after D20581.
- Before patch: accept no-ops internally since the preconditions throw.
- After patch: accept works properly.

Reviewers: amckinley

Reviewed By: amckinley

Differential Revision: https://secure.phabricator.com/D20612

+2 -1
+2 -1
src/applications/diffusion/editor/DiffusionCommitEditEngine.php
··· 48 48 return id(new DiffusionCommitQuery()) 49 49 ->needCommitData(true) 50 50 ->needAuditRequests(true) 51 - ->needAuditAuthority(array($viewer)); 51 + ->needAuditAuthority(array($viewer)) 52 + ->needIdentities(true); 52 53 } 53 54 54 55 protected function getEditorURI() {