mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-26 23:40:57 +01:00
Revert D2542
Summary: Not required after D2730. Test Plan: `arc diff` with invalid reviewer in commit message. Reviewers: nh Reviewed By: nh CC: aran, epriestley Differential Revision: https://secure.phabricator.com/D2733
This commit is contained in:
parent
3718e49f9c
commit
371419344a
4 changed files with 3 additions and 16 deletions
|
@ -69,12 +69,11 @@ final class ConduitAPI_differential_parsecommitmessage_Method
|
|||
$field = $aux_fields[$field_key];
|
||||
try {
|
||||
$fields[$field_key] = $field->parseValueFromCommitMessage($field_value);
|
||||
$field->setValueFromParsedCommitMessage($fields[$field_key]);
|
||||
} catch (DifferentialFieldParseException $ex) {
|
||||
$field_label = $field->renderLabelForCommitMessage();
|
||||
$errors[] = "Error parsing field '{$field_label}': ".$ex->getMessage();
|
||||
$fields[$field_key] = $ex->getPartialParse();
|
||||
}
|
||||
$field->setValueFromParsedCommitMessage($fields[$field_key]);
|
||||
}
|
||||
|
||||
if (!$is_partial) {
|
||||
|
|
|
@ -18,14 +18,4 @@
|
|||
|
||||
final class DifferentialFieldParseException extends Exception {
|
||||
|
||||
private $partialParse;
|
||||
|
||||
public function __construct($message, $partial_parse = null) {
|
||||
parent::__construct($message);
|
||||
$this->partialParse = $partial_parse;
|
||||
}
|
||||
|
||||
public function getPartialParse() {
|
||||
return $this->partialParse;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -768,8 +768,7 @@ abstract class DifferentialFieldSpecification {
|
|||
? "users and mailing lists"
|
||||
: "users";
|
||||
throw new DifferentialFieldParseException(
|
||||
"Commit message references nonexistent {$what}: {$invalid}.",
|
||||
array_unique($results));
|
||||
"Commit message references nonexistent {$what}: {$invalid}.");
|
||||
}
|
||||
|
||||
return array_unique($results);
|
||||
|
|
|
@ -149,8 +149,7 @@ final class DifferentialManiphestTasksFieldSpecification
|
|||
}
|
||||
$invalid = implode(', ', $invalid);
|
||||
throw new DifferentialFieldParseException(
|
||||
"Commit message references nonexistent {$what}: {$invalid}.",
|
||||
$task_phids);
|
||||
"Commit message references nonexistent {$what}: {$invalid}.");
|
||||
}
|
||||
|
||||
return $task_phids;
|
||||
|
|
Loading…
Reference in a new issue