Code Duplication    Length = 7-8 lines in 2 locations

src/CurlClient.php 1 location

@@ 34-41 (lines=8) @@
31
	 *
32
	 * @throws \chillerlan\HTTP\HTTPClientException
33
	 */
34
	public function __construct(ContainerInterface $options){
35
		parent::__construct($options);
36
37
		if(!isset($this->options->ca_info) || !is_file($this->options->ca_info)){
38
			throw new HTTPClientException('invalid CA file');
39
		}
40
41
	}
42
43
	/**
44
	 * @return void

src/StreamClient.php 1 location

@@ 26-32 (lines=7) @@
23
	 *
24
	 * @throws \chillerlan\HTTP\HTTPClientException
25
	 */
26
	public function __construct(ContainerInterface $options){
27
		parent::__construct($options);
28
29
		if(!isset($this->options->ca_info) || !is_file($this->options->ca_info)){
30
			throw new HTTPClientException('invalid CA file');
31
		}
32
	}
33
34
	/** @inheritdoc */
35
	protected function getResponse():HTTPResponseInterface{