|
@@ 241-244 (lines=4) @@
|
| 238 |
|
$instance['color-scheme'] = $this->filter_value( $new_instance['color-scheme'], $this->color_scheme_options ); |
| 239 |
|
$instance['policy-url'] = $this->filter_value( $new_instance['policy-url'], $this->policy_url_options ); |
| 240 |
|
|
| 241 |
|
if ( isset( $new_instance['hide-timeout'] ) ) { |
| 242 |
|
// Time can be a value between 3 and 1000 seconds. |
| 243 |
|
$instance['hide-timeout'] = min( 1000, max( 3, intval( $new_instance['hide-timeout'] ) ) ); |
| 244 |
|
} |
| 245 |
|
|
| 246 |
|
if ( isset( $new_instance['consent-expiration'] ) ) { |
| 247 |
|
// Time can be a value between 1 and 365 days. |
|
@@ 246-249 (lines=4) @@
|
| 243 |
|
$instance['hide-timeout'] = min( 1000, max( 3, intval( $new_instance['hide-timeout'] ) ) ); |
| 244 |
|
} |
| 245 |
|
|
| 246 |
|
if ( isset( $new_instance['consent-expiration'] ) ) { |
| 247 |
|
// Time can be a value between 1 and 365 days. |
| 248 |
|
$instance['consent-expiration'] = min( 365, max( 1, intval( $new_instance['consent-expiration'] ) ) ); |
| 249 |
|
} |
| 250 |
|
|
| 251 |
|
if ( isset( $new_instance['customtext'] ) ) { |
| 252 |
|
$instance['customtext'] = mb_substr( wp_kses( $new_instance['customtext'], array() ), 0, 4096 ); |