Total Complexity | 6 |
Total Lines | 43 |
Duplicated Lines | 0 % |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
13 | class item extends \SimplePie_Item |
||
14 | { |
||
15 | /** |
||
16 | * Magic method handler |
||
17 | * |
||
18 | * @param string $name Property name |
||
19 | * @return mixed |
||
20 | */ |
||
21 | public function __get($name) |
||
22 | { |
||
23 | $method = 'get_' . $name; |
||
24 | return (isset($this, $method)) ? $this->{$method}() : ''; |
||
25 | } |
||
26 | |||
27 | /** |
||
28 | * Magic method handler |
||
29 | * |
||
30 | * @param string $name Property name |
||
31 | * @return bool |
||
32 | */ |
||
33 | public function __isset($name) |
||
36 | } |
||
37 | |||
38 | /** |
||
39 | * Override this method to fix issue in php 7.4 |
||
40 | * Get a single link for the item |
||
41 | * |
||
42 | * @since Beta 3 |
||
43 | * @param int $key The link that you want to return. Remember that arrays begin with 0, not 1 |
||
44 | * @param string $rel The relationship of the link to return |
||
45 | * @return string|null Link URL |
||
46 | */ |
||
47 | public function get_link($key = 0, $rel = 'alternate') |
||
58 |