@@ -203,6 +203,10 @@ |
||
203 | 203 | return $models; |
204 | 204 | } |
205 | 205 | |
206 | + /** |
|
207 | + * @param string $property |
|
208 | + * @param string $value |
|
209 | + */ |
|
206 | 210 | public static function find_one_by_property( $property, $value ) { |
207 | 211 | global $wpdb; |
208 | 212 |
@@ -154,6 +154,11 @@ |
||
154 | 154 | return $button->render($size, $autowidth, $style, $format, $color, $hide, $buttonid, $language); |
155 | 155 | } |
156 | 156 | |
157 | + /** |
|
158 | + * @param string $key |
|
159 | + * |
|
160 | + * @return string|null |
|
161 | + */ |
|
157 | 162 | public static function get_array_value_with_fallback($args, $key) { |
158 | 163 | if ( isset($args[$key]) ) |
159 | 164 | return $args[$key]; |
@@ -92,6 +92,7 @@ discard block |
||
92 | 92 | |
93 | 93 | /** |
94 | 94 | * Helper method: redirect to a certain page. |
95 | + * @param string $action |
|
95 | 96 | */ |
96 | 97 | public static function redirect( $action, $button_id = NULL, $params = array(), $network = FALSE ) { |
97 | 98 | $page = ( $network ? '/network/settings' : 'options-general' ) . '.php?page=' . filter_input(INPUT_GET, 'page'); |
@@ -211,6 +212,9 @@ discard block |
||
211 | 212 | endif; |
212 | 213 | } |
213 | 214 | |
215 | + /** |
|
216 | + * @param string $action |
|
217 | + */ |
|
214 | 218 | private static function form_template( $button, $action ) { |
215 | 219 | // Enqueue Scripts for Media Manager |
216 | 220 | wp_enqueue_media(); |