Plugin
last analyzed

Size/Duplication

Total Lines 3
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
dl 0
loc 3
ccs 0
cts 0
cp 0
c 0
b 0
f 0
1
<?php
2
3
namespace Http\Client\Plugin;
4
5
@trigger_error('The '.__NAMESPACE__.'\Plugin class is deprecated since version 1.1 and will be removed in 2.0. Use Http\Client\Common\Plugin instead.', E_USER_DEPRECATED);
0 ignored issues
show
Security Best Practice introduced by
It seems like you do not handle an error condition here. This can introduce security issues, and is generally not recommended.

If you suppress an error, we recommend checking for the error condition explicitly:

// For example instead of
@mkdir($dir);

// Better use
if (@mkdir($dir) === false) {
    throw new \RuntimeException('The directory '.$dir.' could not be created.');
}
Loading history...
6
7
/**
8
 * A plugin is a middleware to transform the request and/or the response.
9
 *
10
 * The plugin can:
11
 *  - break the chain and return a response
12
 *  - dispatch the request to the next middleware
13
 *  - restart the request
14
 *
15
 * @author Joel Wurtz <[email protected]>
16
 *
17
 * @deprecated since since version 1.1, and will be removed in 2.0. Use {@link \Http\Client\Common\Plugin} instead.
18
 */
19
interface Plugin extends \Http\Client\Common\Plugin
20
{
21
}
22