mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-22 21:40:55 +01:00
Display other locations of lint errors
Summary: Depends on D4392. I don't plan on adding these to changesets. Test Plan: Added `$message['locations'] = array(array('line' => 10));` in the code and displayed a revision with lint problems. Reviewers: epriestley Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D4394
This commit is contained in:
parent
d04bc0747c
commit
dbeb60adbe
1 changed files with 11 additions and 0 deletions
|
@ -116,6 +116,17 @@ final class DifferentialLintFieldSpecification
|
|||
'show' => $show,
|
||||
);
|
||||
|
||||
if (isset($message['locations'])) {
|
||||
$locations = array();
|
||||
foreach ($message['locations'] as $location) {
|
||||
$other_line = idx($location, 'line');
|
||||
$locations[] =
|
||||
idx($location, 'path', $path).
|
||||
($other_line ? ":{$other_line}" : "");
|
||||
}
|
||||
$description .= "\nOther locations: ".implode(", ", $locations);
|
||||
}
|
||||
|
||||
if (strlen($description)) {
|
||||
$rows[] = array(
|
||||
'style' => 'details',
|
||||
|
|
Loading…
Reference in a new issue