mirror of
https://we.phorge.it/source/arcanist.git
synced 2024-11-22 14:52:40 +01:00
Catch "ConduitClientException", not "Exception", in "arc patch"
Summary: This may raise other types of exceptions, e.g. http/network exceptions, where getErrorCode() is not defined. Test Plan: Reasoned about beahvior. Reviewers: btrahan Reviewed By: btrahan CC: aran, epriestley Differential Revision: https://secure.phabricator.com/D1804
This commit is contained in:
parent
81019a790e
commit
2c26304dd2
1 changed files with 1 additions and 1 deletions
|
@ -349,7 +349,7 @@ EOTEXT
|
||||||
$param);
|
$param);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
} catch (Exception $ex) {
|
} catch (ConduitClientException $ex) {
|
||||||
if ($ex->getErrorCode() == 'ERR-INVALID-SESSION') {
|
if ($ex->getErrorCode() == 'ERR-INVALID-SESSION') {
|
||||||
// Phabricator is not configured to allow anonymous access to
|
// Phabricator is not configured to allow anonymous access to
|
||||||
// Differential.
|
// Differential.
|
||||||
|
|
Loading…
Reference in a new issue