diff options
author | Adam Wight <adam.wight@wikimedia.de> | 2019-12-13 10:58:24 +0100 |
---|---|---|
committer | Bartosz DziewoĆski <dziewonski@fastmail.fm> | 2024-09-17 22:20:58 +0200 |
commit | 188d2cbbb00d870c20cafeafac56e20c8f520291 (patch) | |
tree | 3b04e7011f80769af889bd4350f72c967bc412a1 /includes/http/GuzzleHttpRequest.php | |
parent | 8c803338a5ddeea69467540d28c795ef9ff16107 (diff) | |
download | mediawikicore-188d2cbbb00d870c20cafeafac56e20c8f520291.tar.gz mediawikicore-188d2cbbb00d870c20cafeafac56e20c8f520291.zip |
Remove unchecked exception annotations
Callers should not catch an unchecked exception, so it doesn't belong
in a function signature. Unchecked exceptions indicate a coding error,
which by definition the code will not be able to handle correctly.
If any of these exceptions were supposed to be in response to an edge
case, user input, or initial conditions, then they should be changed
to a runtime error. If the exception class cannot be changed, then
the annotation should include a comment explaining its purpose and
prognosis.
Bug: T240672
Change-Id: I2e640b9737cb68090a8e1cb70067d1b74037d647
Diffstat (limited to 'includes/http/GuzzleHttpRequest.php')
-rw-r--r-- | includes/http/GuzzleHttpRequest.php | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/includes/http/GuzzleHttpRequest.php b/includes/http/GuzzleHttpRequest.php index d4d5b471bbd1..3ce7283dfb50 100644 --- a/includes/http/GuzzleHttpRequest.php +++ b/includes/http/GuzzleHttpRequest.php @@ -93,7 +93,6 @@ class GuzzleHttpRequest extends MWHttpRequest { * This function overrides any 'sink' or 'callback' constructor option. * * @param callable|null $callback - * @throws InvalidArgumentException */ public function setCallback( $callback ) { $this->sink = null; @@ -108,7 +107,6 @@ class GuzzleHttpRequest extends MWHttpRequest { * option to override the 'callback' constructor option. * * @param callable|null $callback - * @throws InvalidArgumentException */ protected function doSetCallback( $callback ) { if ( !$this->sink ) { |