| @@ 930-936 (lines=7) @@ | ||
| 927 | Settings::update_settings( $sync_settings ); |
|
| 928 | ||
| 929 | // Convert comma-delimited string of modules to an array |
|
| 930 | if ( ! empty( $assoc_args['modules'] ) ) { |
|
| 931 | $modules = array_map( 'trim', explode( ',', $assoc_args['modules'] ) ); |
|
| 932 | ||
| 933 | // Convert the array so that the keys are the module name and the value is true to indicate |
|
| 934 | // that we want to sync the module |
|
| 935 | $modules = array_map( '__return_true', array_flip( $modules ) ); |
|
| 936 | } |
|
| 937 | ||
| 938 | foreach ( array( 'posts', 'comments', 'users' ) as $module_name ) { |
|
| 939 | if ( |
|
| @@ 3062-3064 (lines=3) @@ | ||
| 3059 | if ( ! empty( $attributes['options'] ) && is_string( $attributes['options'] ) ) { |
|
| 3060 | $attributes['options'] = array_map( 'trim', explode( ',', $attributes['options'] ) ); |
|
| 3061 | ||
| 3062 | if ( ! empty( $attributes['values'] ) && is_string( $attributes['values'] ) ) { |
|
| 3063 | $attributes['values'] = array_map( 'trim', explode( ',', $attributes['values'] ) ); |
|
| 3064 | } |
|
| 3065 | } |
|
| 3066 | ||
| 3067 | if ( $form ) { |
|