| Total Complexity | 5 |
| Total Lines | 28 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 8 | class Form extends Component |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * @var string |
||
| 12 | */ |
||
| 13 | public $method; |
||
| 14 | |||
| 15 | public function __construct(string $method = 'get') |
||
| 16 | { |
||
| 17 | $this->method = $method; |
||
| 18 | } |
||
| 19 | |||
| 20 | public function httpMethod() |
||
| 21 | { |
||
| 22 | if ($this->spoofedMethod()) { |
||
| 23 | return 'post'; |
||
| 24 | } |
||
| 25 | |||
| 26 | return $this->method; |
||
| 27 | } |
||
| 28 | |||
| 29 | public function spoofedMethod() |
||
| 32 | } |
||
| 33 | public function render() |
||
| 34 | { |
||
| 38 |