From f2bc293a2aeada79a55dbe1ce8bd71f166609bda Mon Sep 17 00:00:00 2001 From: epriestley Date: Mon, 27 Jan 2014 18:49:35 -0800 Subject: [PATCH] Use remote URI, not display URI, to match repositories Summary: I derped this up, and it passed my tests because the two URIs are the same for hosted repositories. Match repositories against their remote URI (like `https://github.com/user/repo.git`), not their display URI (like `/diffusion/X/`). Test Plan: i r dums Reviewers: talshiri, btrahan Reviewed By: talshiri CC: aran Differential Revision: https://secure.phabricator.com/D8082 --- .../repository/storage/PhabricatorRepository.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/applications/repository/storage/PhabricatorRepository.php b/src/applications/repository/storage/PhabricatorRepository.php index 06aeb21105..a9feda8656 100644 --- a/src/applications/repository/storage/PhabricatorRepository.php +++ b/src/applications/repository/storage/PhabricatorRepository.php @@ -490,17 +490,17 @@ final class PhabricatorRepository extends PhabricatorRepositoryDAO case PhabricatorRepositoryType::REPOSITORY_TYPE_GIT: $normalized_uri = new PhabricatorRepositoryURINormalizer( PhabricatorRepositoryURINormalizer::TYPE_GIT, - $this->getURI()); + $this->getRemoteURI()); break; case PhabricatorRepositoryType::REPOSITORY_TYPE_SVN: $normalized_uri = new PhabricatorRepositoryURINormalizer( PhabricatorRepositoryURINormalizer::TYPE_SVN, - $this->getURI()); + $this->getRemoteURI()); break; case PhabricatorRepositoryType::REPOSITORY_TYPE_MERCURIAL: $normalized_uri = new PhabricatorRepositoryURINormalizer( PhabricatorRepositoryURINormalizer::TYPE_MERCURIAL, - $this->getURI()); + $this->getRemoteURI()); break; default: throw new Exception("Unrecognized version control system.");