Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logging changes of settings in Customizer #827

Merged
merged 3 commits into from Mar 10, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions connectors/class-connector-settings.php
Expand Up @@ -541,7 +541,7 @@ function( $rule ) use ( $submenu, $record ) {
}

/**
* Trigger this connector from WP CLI, only for known Settings
* Trigger this connector from WP CLI or the Customizer, only for known Settings
*
* @action update_option
*
Expand All @@ -550,7 +550,7 @@ function( $rule ) use ( $submenu, $record ) {
* @param mixed $value
*/
public function callback_update_option( $option, $value, $old_value ) {
if ( defined( '\WP_CLI' ) && \WP_CLI && array_key_exists( $option, $this->labels ) ) {
if ( ( defined( '\WP_CLI' ) && \WP_CLI || did_action( 'customize_save' ) ) && array_key_exists( $option, $this->labels ) ) {
$this->callback_updated_option( $option, $value, $old_value );
}
}
Expand Down