1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-09-20 09:18:48 +02:00

add projectName to conduit.getdiff

Summary: some ground work for T479

Test Plan:
called up a diff via the conduit api console
it had the right project name and did not error

Reviewers: epriestley

Reviewed By: epriestley

CC: aran, btrahan, epriestley

Differential Revision: 1139
This commit is contained in:
Bob Trahan 2011-11-29 14:55:50 -08:00
parent 0511bf36b3
commit d0d33094d6

View file

@ -76,7 +76,19 @@ class ConduitAPI_differential_getdiff_Method extends ConduitAPIMethod {
$changeset->attachHunks($changeset->loadHunks());
}
return $diff->getDiffDict();
$basic_dict = $diff->getDiffDict();
// for conduit calls, the basic dict is not enough
// we also need to include the arcanist project
$project = $diff->loadArcanistProject();
if ($project) {
$project_name = $project->getName();
} else {
$project_name = '';
}
$basic_dict['projectName'] = $project_name;
return $basic_dict;
}
}