Skip to content

Commit

Permalink
lint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
tharsheblows committed Aug 23, 2024
1 parent 66f4726 commit 44f39f4
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions classes/class-network.php
Original file line number Diff line number Diff line change
Expand Up @@ -371,23 +371,23 @@ public function network_options_action() {

$option = ! empty( $_POST['option_page'] ) ? $_POST['option_page'] : false;

if ( $option && $this->network_settings_option === $option ){
if ( $option && $this->network_settings_option === $option ) {
$value = array();
$sections = $this->plugin->settings->get_fields();

foreach ( $sections as $section_name => $section ) {
foreach ( $section['fields'] as $field_idx => $field ) {
$option_key = $section_name . '_' . $field['name'];
foreach ( $sections as $section_name => $section ) {
foreach ( $section['fields'] as $field_idx => $field ) {
$option_key = $section_name . '_' . $field['name'];

if ( isset( $_POST[ $option ][ $option_key ] ) ) {
$value[ $option_key ] = $this->plugin->settings->sanitize_setting_by_field_type( $_POST[ $option ][ $option_key ], $field['type'] );
} else {
$value[ $option_key ] = false;
}
if ( isset( $_POST[ $option ][ $option_key ] ) ) {
$value[ $option_key ] = $this->plugin->settings->sanitize_setting_by_field_type( $_POST[ $option ][ $option_key ], $field['type'] );
} else {
$value[ $option_key ] = false;
}
}
}

update_site_option( $this->network_settings_option, $value );
update_site_option( $this->network_settings_option, $value );
}

if ( ! count( get_settings_errors() ) ) {
Expand Down

0 comments on commit 44f39f4

Please sign in to comment.