PluginProbe
Polylang / 3.6.7
Polylang v3.6.7
3.8.9 3.8.8 3.8.7 3.8.6 3.8.5 3.8.4 3.8.3 2.7 2.7.0.1 2.7.1 2.7.2 2.7.3 2.7.4 2.8 2.8.1 2.8.2 2.8.3 2.8.4 2.9 2.9.1 2.9.2 3.0 3.0.1 3.0.2 3.0.3 All 233 releases
← All changes | modules/sync/settings-sync.php +9 -8 2.83.6.7 View file →
@@ -20,9 +20,9 @@
20 20 * Constructor
21 21 *
22 22 * @since 1.8
23 23 *
24 - * @param object $polylang polylang object
24 + * @param object $polylang The polylang object.
25 25 */
26 26 public function __construct( &$polylang ) {
27 27 parent::__construct(
28 28 $polylang,
@@ -66,25 +66,26 @@
66 66 <?php
67 67 }
68 68
69 69 /**
70 - * Sanitizes the settings before saving
70 + * Sanitizes the settings before saving.
71 71 *
72 72 * @since 1.8
73 73 *
74 - * @param array $options
74 + * @param array $options Unsanitized options to save.
75 + * @return array
75 76 */
76 77 protected function update( $options ) {
77 78 $newoptions = array( 'sync' => empty( $options['sync'] ) ? array() : array_keys( $options['sync'], 1 ) );
78 - return $newoptions; // take care to return only validated options
79 + return $newoptions; // Take care to return only validated options.
79 80 }
80 81
81 82 /**
82 - * Get the row actions
83 + * Get the row actions.
83 84 *
84 85 * @since 1.8
85 86 *
86 - * @return array
87 + * @return string[] Row actions.
87 88 */
88 89 protected function get_actions() {
89 90 return empty( $this->options['sync'] ) ? array( 'configure' ) : array( 'configure', 'deactivate' );
90 91 }
@@ -89,13 +90,13 @@
89 90 return empty( $this->options['sync'] ) ? array( 'configure' ) : array( 'configure', 'deactivate' );
90 91 }
91 92
92 93 /**
93 - * List the post metas to synchronize
94 + * Get the list of synchronization settings.
94 95 *
95 96 * @since 1.0
96 97 *
97 - * @return array
98 + * @return string[] Array synchronization options.
98 99 */
99 100 public static function list_metas_to_sync() {
100 101 return array(
101 102 'taxonomies' => __( 'Taxonomies', 'polylang' ),