Skip to content

Commit 921d56e

Browse files
author
epriestley
committedJul 5, 2016
Make repository URI creation work regardless of "repository" transaction order
Summary: Fixes T11276. This feels slightly iffy (we `attachRepository()` here, and also when applying the TYPE_REPOSITORY transaction) but simpler than trying to reorder things. Test Plan: Created a repository URI with transactions in `["uri", "repository"]` order. Reviewers: chad, avivey Reviewed By: avivey Maniphest Tasks: T11276 Differential Revision: https://secure.phabricator.com/D16237
1 parent 5ffdb73 commit 921d56e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed
 

‎src/applications/diffusion/editor/DiffusionURIEditor.php

+5
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,11 @@ protected function applyCustomInternalTransaction(
7777
$old_uri = $object->getEffectiveURI();
7878
} else {
7979
$old_uri = null;
80+
81+
// When creating a URI, we may not have processed the repository
82+
// transaction yet. Attach the repository here to make sure we
83+
// have it for the calls below.
84+
$object->attachRepository($this->repository);
8085
}
8186

8287
$object->setURI($xaction->getNewValue());

0 commit comments

Comments
 (0)
Failed to load comments.