Conditions | 3 |
Paths | 3 |
Total Lines | 15 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
22 | protected function set_type() { |
||
23 | global $wp_version; |
||
24 | |||
25 | if ( version_compare( $wp_version, '4.8' ) >= 0 ) { |
||
26 | $this->type = 'kirki-editor'; |
||
27 | return; |
||
28 | } |
||
29 | |||
30 | // Fallback for older WordPress versions. |
||
31 | $this->type = 'kirki-generic'; |
||
32 | if ( ! is_array( $this->choices ) ) { |
||
|
|||
33 | $this->choices = array(); |
||
34 | } |
||
35 | $this->choices['element'] = 'textarea'; |
||
36 | $this->choices['rows'] = '5'; |
||
37 | } |
||
54 |