Skip to content

Commit

Permalink
(stable) Promote 2017 Week 1
Browse files Browse the repository at this point in the history
  • Loading branch information
epriestley committed Jan 7, 2017
2 parents e8b580d + ade25fa commit 9503b94
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/workflow/ArcanistDiffWorkflow.php
Original file line number Diff line number Diff line change
Expand Up @@ -1962,7 +1962,13 @@ private function parseCommitMessagesIntoFields(array $local) {
$faux_message[] = pht('CC: %s', $this->getArgument('cc'));
}

// See T12069. After T10312, the first line of a message is always parsed
// as a title. Add a placeholder so "Reviewers" and "CC" are never the
// first line.
$placeholder_title = pht('<placeholder>');

if ($faux_message) {
array_unshift($faux_message, $placeholder_title);
$faux_message = implode("\n\n", $faux_message);
$local = array(
'(Flags) ' => array(
Expand Down Expand Up @@ -2034,6 +2040,10 @@ private function parseCommitMessagesIntoFields(array $local) {
continue;
}

if ($title === $placeholder_title) {
continue;
}

if (!isset($result['title'])) {
// We don't have a title yet, so use this one.
$result['title'] = $title;
Expand Down

0 comments on commit 9503b94

Please sign in to comment.