Skip to content

Commit

Permalink
Fix bug where disabling Static CDN Filters did not update htaccess
Browse files Browse the repository at this point in the history
  • Loading branch information
raamdev committed Jun 27, 2016
1 parent 4ec5801 commit 7895579
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/includes/classes/Actions.php
Expand Up @@ -557,6 +557,10 @@ protected function saveOptions($args)
if (IS_PRO && $this->plugin->options['enable'] && !$this->plugin->options['cdn_enable'] && $args['cdn_enable']) {
$args['htaccess_access_control_allow_origin'] = 1;
}
// Auto-disable `htaccess_access_control_allow_origin` option only when Static CDN Filters are being disabled
if (IS_PRO && $this->plugin->options['enable'] && !$args['cdn_enable']) {
$args['htaccess_access_control_allow_origin'] = 0;
}
$args = $this->plugin->trimDeep(stripslashes_deep((array) $args));
$this->plugin->updateOptions($args); // Save/update options.

Expand Down

0 comments on commit 7895579

Please sign in to comment.