mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-15 01:50:55 +01:00
(stable) Fix an issue where blame could fatal for unrecognized authors
Summary: See PHI255. See <https://discourse.phabricator-community.org/t/error-generating-blame-data/766>. Test Plan: - Viewed a file contributed to by users with no Phabricator user accounts, in Diffusion. - Enabled blame. - Before patch: blame failed, fatal in logs. - After patch: blame worked. Reviewers: amckinley Reviewed By: amckinley Differential Revision: https://secure.phabricator.com/D18833
This commit is contained in:
parent
f56124dc93
commit
563d42d40e
1 changed files with 9 additions and 5 deletions
|
@ -1804,10 +1804,17 @@ final class DiffusionBrowseController extends DiffusionController {
|
|||
// revision. We just render a blank for alignment.
|
||||
$style = null;
|
||||
$href = null;
|
||||
$sigil = null;
|
||||
$meta = null;
|
||||
} else {
|
||||
$src = $handles[$phid]->getImageURI();
|
||||
$style = 'background-image: url('.$src.');';
|
||||
$href = $handles[$phid]->getURI();
|
||||
$sigil = 'has-tooltip';
|
||||
$meta = array(
|
||||
'tip' => $handles[$phid]->getName(),
|
||||
'align' => 'E',
|
||||
);
|
||||
}
|
||||
|
||||
$links[$phid] = javelin_tag(
|
||||
|
@ -1816,11 +1823,8 @@ final class DiffusionBrowseController extends DiffusionController {
|
|||
'class' => 'diffusion-author-link',
|
||||
'style' => $style,
|
||||
'href' => $href,
|
||||
'sigil' => 'has-tooltip',
|
||||
'meta' => array(
|
||||
'tip' => $handles[$phid]->getName(),
|
||||
'align' => 'E',
|
||||
),
|
||||
'sigil' => $sigil,
|
||||
'meta' => $meta,
|
||||
));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue