@@ -115,6 +115,11 @@ discard block |
||
115 | 115 | } |
116 | 116 | |
117 | 117 | // /sites/%s/taxonomies/%s/terms/new -> $blog_id, $taxonomy |
118 | + |
|
119 | + /** |
|
120 | + * @param string $path |
|
121 | + * @param string $taxonomy |
|
122 | + */ |
|
118 | 123 | function new_term( $path, $blog_id, $taxonomy ) { |
119 | 124 | $args = $this->query_args(); |
120 | 125 | $input = $this->input(); |
@@ -160,6 +165,12 @@ discard block |
||
160 | 165 | } |
161 | 166 | |
162 | 167 | // /sites/%s/taxonomies/%s/terms/slug:%s -> $blog_id, $taxonomy, $slug |
168 | + |
|
169 | + /** |
|
170 | + * @param string $path |
|
171 | + * @param string $slug |
|
172 | + * @param string $taxonomy |
|
173 | + */ |
|
163 | 174 | function update_term( $path, $blog_id, $slug, $taxonomy ) { |
164 | 175 | $tax = get_taxonomy( $taxonomy ); |
165 | 176 | if ( ! current_user_can( $tax->cap->edit_terms ) ) { |
@@ -208,6 +219,12 @@ discard block |
||
208 | 219 | } |
209 | 220 | |
210 | 221 | // /sites/%s/taxonomies/%s/terms/slug:%s/delete -> $blog_id, $taxonomy, $slug |
222 | + |
|
223 | + /** |
|
224 | + * @param string $path |
|
225 | + * @param string $slug |
|
226 | + * @param string $taxonomy |
|
227 | + */ |
|
211 | 228 | function delete_term( $path, $blog_id, $slug, $taxonomy ) { |
212 | 229 | $term = get_term_by( 'slug', $slug, $taxonomy ); |
213 | 230 | $tax = get_taxonomy( $taxonomy ); |
@@ -77,6 +77,9 @@ discard block |
||
77 | 77 | add_action( 'wp_logout', array( $this, 'maybe_logout_user_from_wpcom' ) ); |
78 | 78 | } |
79 | 79 | |
80 | + /** |
|
81 | + * @param string $site_slug |
|
82 | + */ |
|
80 | 83 | private function initialize_tracks_events( $site_slug ) { |
81 | 84 | JetpackTracking::add_redirect( array ( |
82 | 85 | //my sites - top level items |
@@ -182,6 +185,9 @@ discard block |
||
182 | 185 | wp_enqueue_script( 'a8c_wpcom_masterbar_overrides', $this->wpcom_static_url( '/wp-content/mu-plugins/admin-bar/masterbar-overrides/masterbar.js' ), array( 'jquery' ), JETPACK__VERSION ); |
183 | 186 | } |
184 | 187 | |
188 | + /** |
|
189 | + * @param string $file |
|
190 | + */ |
|
185 | 191 | function wpcom_static_url( $file ) { |
186 | 192 | if ( ! empty( $this->sandbox_url ) ) { |
187 | 193 | // For testing undeployed changes to remotely enqueued scripts and styles. |
@@ -364,6 +370,9 @@ discard block |
||
364 | 370 | return $primary_anchor . $secondary_anchor; |
365 | 371 | } |
366 | 372 | |
373 | + /** |
|
374 | + * @param string $class |
|
375 | + */ |
|
367 | 376 | public function create_menu_item_anchor( $class, $url, $label, $id ) { |
368 | 377 | return '<a href="' . $url . '" class="' . $class . '" id="' . $id . '">' . $label . '</a>'; |
369 | 378 | } |