1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-18 19:40:55 +01:00

Hide repository from atom view if it hasn't been set

Summary: Fixes T8626. I guess that `$this->getViewer()->renderHandle(null)` renders as "Unknown Object", which is somewhat odd to me.

Test Plan: Viewed an atom from a book without a repository linked to it.

Reviewers: epriestley, #blessed_reviewers

Reviewed By: epriestley, #blessed_reviewers

Subscribers: epriestley, Korvin

Maniphest Tasks: T8626

Differential Revision: https://secure.phabricator.com/D13370
This commit is contained in:
Joshua Spence 2015-06-21 11:08:54 +10:00
parent b24bdf0288
commit f9e838024c

View file

@ -300,6 +300,10 @@ final class DivinerAtomController extends DivinerController {
PHUIPropertyListView $view,
DivinerLiveSymbol $symbol) {
if (!$symbol->getRepositoryPHID()) {
return;
}
$view->addProperty(
pht('Repository'),
$this->getViewer()->renderHandle($symbol->getRepositoryPHID()));