Tribe__Settings_Manager::update_options_cache( string $option, mixed $old_value, mixed $value )
For performance reasons our options are saved in memory, but we need to make sure we update it when WordPress updates the variable directly.
Contents
Parameters
- $option
-
(string) (Required) Name of the updated option.
- $old_value
-
(mixed) (Required) The old option value.
- $value
-
(mixed) (Required) The new option value.
Return
(void)
Source
File: src/Tribe/Settings_Manager.php
public function update_options_cache( $option, $old_value, $value ) {
// Bail when no our option.
if ( Tribe__Main::OPTIONNAME !== $option ) {
return;
}
tribe_set_var( self::OPTION_CACHE_VAR_NAME, $value );
}
Changelog
| Version | Description |
|---|---|
| 4.11.0 | Introduced. |