@@ -2019,8 +2019,8 @@ discard block |
||
| 2019 | 2019 | * |
| 2020 | 2020 | * @param string|array $sql The SQL to execute |
| 2021 | 2021 | * @param string $error Error to throw on problems |
| 2022 | - * @param null $results_error (optional) |
|
| 2023 | - * @param null $no_results_error (optional) |
|
| 2022 | + * @param string|null $results_error (optional) |
|
| 2023 | + * @param string|null $no_results_error (optional) |
|
| 2024 | 2024 | * |
| 2025 | 2025 | * @return array|bool|mixed|null|void Result of the query |
| 2026 | 2026 | * |
@@ -2347,7 +2347,7 @@ discard block |
||
| 2347 | 2347 | /** |
| 2348 | 2348 | * Get the string to use in a query for matching, uses WP_Query meta_query arguments |
| 2349 | 2349 | * |
| 2350 | - * @param string|int $field Field name or array index |
|
| 2350 | + * @param string $field Field name or array index |
|
| 2351 | 2351 | * @param array|string $q Query array (meta_query) or string for matching |
| 2352 | 2352 | * @param array $pod Related Pod |
| 2353 | 2353 | * @param object $params Parameters passed from select() |
@@ -332,6 +332,9 @@ discard block |
||
| 332 | 332 | self::$settings = pods_api()->load_pods( array( 'type' => 'settings', 'refresh' => true ) ); |
| 333 | 333 | } |
| 334 | 334 | |
| 335 | + /** |
|
| 336 | + * @param string $type |
|
| 337 | + */ |
|
| 335 | 338 | public function register ( $type, $pod ) { |
| 336 | 339 | $pod_type = $type; |
| 337 | 340 | |
@@ -795,7 +798,7 @@ discard block |
||
| 795 | 798 | } |
| 796 | 799 | |
| 797 | 800 | /** |
| 798 | - * @param $type |
|
| 801 | + * @param string $type |
|
| 799 | 802 | * @param $name |
| 800 | 803 | * @param $default_fields |
| 801 | 804 | * |
@@ -2688,7 +2691,7 @@ discard block |
||
| 2688 | 2691 | * @param string $meta_value |
| 2689 | 2692 | * @param bool $unique |
| 2690 | 2693 | * |
| 2691 | - * @return bool|int|null |
|
| 2694 | + * @return null|integer |
|
| 2692 | 2695 | */ |
| 2693 | 2696 | public function add_meta ( $object_type, $_null = null, $object_id = 0, $meta_key = '', $meta_value = '', $unique = false ) { |
| 2694 | 2697 | if ( pods_tableless() ) |
@@ -2729,7 +2732,7 @@ discard block |
||
| 2729 | 2732 | * @param string $meta_value |
| 2730 | 2733 | * @param string $prev_value |
| 2731 | 2734 | * |
| 2732 | - * @return bool|int|null |
|
| 2735 | + * @return null|integer |
|
| 2733 | 2736 | */ |
| 2734 | 2737 | public function update_meta ( $object_type, $_null = null, $object_id = 0, $meta_key = '', $meta_value = '', $prev_value = '' ) { |
| 2735 | 2738 | if ( pods_tableless() ) |
@@ -2870,6 +2873,9 @@ discard block |
||
| 2870 | 2873 | return $this->delete_object( 'media', $id ); |
| 2871 | 2874 | } |
| 2872 | 2875 | |
| 2876 | + /** |
|
| 2877 | + * @param string $type |
|
| 2878 | + */ |
|
| 2873 | 2879 | public function delete_object ( $type, $id, $name = null ) { |
| 2874 | 2880 | if ( empty( $name ) ) |
| 2875 | 2881 | $name = $type; |
@@ -359,7 +359,7 @@ |
||
| 359 | 359 | * $params['name'] string Field name |
| 360 | 360 | * |
| 361 | 361 | * @param array $params An associative array of parameters |
| 362 | - * @param null $obj |
|
| 362 | + * @param Pods $obj |
|
| 363 | 363 | * |
| 364 | 364 | * @return mixed Anything returned by the helper |
| 365 | 365 | * @since 2.0 |
@@ -310,7 +310,6 @@ discard block |
||
| 310 | 310 | /** |
| 311 | 311 | * Determine if Deprecated Mode is enabled |
| 312 | 312 | * |
| 313 | - * @param bool $include_debug Whether to include strict mode |
|
| 314 | 313 | * |
| 315 | 314 | * @return bool Whether Deprecated Mode is enabled |
| 316 | 315 | * |
@@ -443,6 +442,7 @@ discard block |
||
| 443 | 442 | * @param string $minimum_version Minimum version |
| 444 | 443 | * @param string $comparison Comparison operator |
| 445 | 444 | * @param string $maximum_version Maximum version |
| 445 | + * @param string $what |
|
| 446 | 446 | * |
| 447 | 447 | * @return bool |
| 448 | 448 | */ |
@@ -906,7 +906,7 @@ discard block |
||
| 906 | 906 | * @uses get_shortcode_regex() Gets the search pattern for searching shortcodes. |
| 907 | 907 | * |
| 908 | 908 | * @param string $content Content to search for shortcodes |
| 909 | - * @param array $shortcodes Array of shortcodes to run |
|
| 909 | + * @param string[] $shortcodes Array of shortcodes to run |
|
| 910 | 910 | * @return string Content with shortcodes filtered out. |
| 911 | 911 | */ |
| 912 | 912 | function pods_do_shortcode( $content, $shortcodes ) { |
@@ -1446,7 +1446,7 @@ discard block |
||
| 1446 | 1446 | * @param string|bool $key Key for the cache |
| 1447 | 1447 | * @param string $group (optional) Key for the group |
| 1448 | 1448 | * |
| 1449 | - * @return bool|mixed|null|void |
|
| 1449 | + * @return boolean |
|
| 1450 | 1450 | * |
| 1451 | 1451 | * @since 2.0 |
| 1452 | 1452 | */ |
@@ -1654,7 +1654,6 @@ discard block |
||
| 1654 | 1654 | * |
| 1655 | 1655 | * @param string|array $pod The pod name or array of pod names |
| 1656 | 1656 | * @param string $name The name of the Pod |
| 1657 | - * @param array $object (optional) Pod array, including any 'fields' arrays |
|
| 1658 | 1657 | * |
| 1659 | 1658 | * @return array|boolean Field data or false if unsuccessful |
| 1660 | 1659 | * @since 2.1 |
@@ -935,7 +935,7 @@ |
||
| 935 | 935 | * @param $args |
| 936 | 936 | * @param string $type |
| 937 | 937 | * |
| 938 | - * @return array |
|
| 938 | + * @return string |
|
| 939 | 939 | */ |
| 940 | 940 | public static function object_label_fix( $args, $type = 'post_type' ) { |
| 941 | 941 | |
@@ -1559,7 +1559,7 @@ discard block |
||
| 1559 | 1559 | * |
| 1560 | 1560 | * @param array $params An associative array of parameters |
| 1561 | 1561 | * @param bool $sanitized (optional) Decides whether the params have been sanitized before being passed, will sanitize them if false. |
| 1562 | - * @param bool|int $db (optional) Whether to save into the DB or just return Pod array. |
|
| 1562 | + * @param boolean $db (optional) Whether to save into the DB or just return Pod array. |
|
| 1563 | 1563 | * |
| 1564 | 1564 | * @return int Pod ID |
| 1565 | 1565 | * @since 1.7.9 |
@@ -3903,7 +3903,7 @@ discard block |
||
| 3903 | 3903 | * Save relationships |
| 3904 | 3904 | * |
| 3905 | 3905 | * @param int $id ID of item |
| 3906 | - * @param int|array $related_id ID or IDs to save |
|
| 3906 | + * @param int|array $related_ids ID or IDs to save |
|
| 3907 | 3907 | * @param array $pod Pod data |
| 3908 | 3908 | * @param array $field Field data |
| 3909 | 3909 | */ |
@@ -5061,7 +5061,6 @@ discard block |
||
| 5061 | 5061 | * Delete an object from tableless fields |
| 5062 | 5062 | * |
| 5063 | 5063 | * @param int $id |
| 5064 | - * @param string $type |
|
| 5065 | 5064 | * @param string $name |
| 5066 | 5065 | * |
| 5067 | 5066 | * @return bool |
@@ -5284,6 +5283,7 @@ discard block |
||
| 5284 | 5283 | * $params['name'] string Pod name |
| 5285 | 5284 | * |
| 5286 | 5285 | * @param array $params An associative array of parameters |
| 5286 | + * @param string $type |
|
| 5287 | 5287 | * |
| 5288 | 5288 | * @return bool True if exists |
| 5289 | 5289 | * |
@@ -6792,7 +6792,7 @@ discard block |
||
| 6792 | 6792 | * @param string $type Field type to look for |
| 6793 | 6793 | * @param array $options (optional) Options of the field to pass to the schema function. |
| 6794 | 6794 | * |
| 6795 | - * @return array|bool|mixed|null |
|
| 6795 | + * @return string |
|
| 6796 | 6796 | * |
| 6797 | 6797 | * @since 2.0 |
| 6798 | 6798 | */ |
@@ -7228,7 +7228,7 @@ discard block |
||
| 7228 | 7228 | * |
| 7229 | 7229 | * Load the information about an objects MySQL table |
| 7230 | 7230 | * |
| 7231 | - * @param $object_type |
|
| 7231 | + * @param string $object_type |
|
| 7232 | 7232 | * @param string $object The object to look for |
| 7233 | 7233 | * @param null $name (optional) Name of the pod to load |
| 7234 | 7234 | * @param array $pod (optional) Array with pod information |
@@ -330,7 +330,7 @@ discard block |
||
| 330 | 330 | /** |
| 331 | 331 | * Rewind Iterator |
| 332 | 332 | * |
| 333 | - * @return void|boolean |
|
| 333 | + * @return null|false |
|
| 334 | 334 | * |
| 335 | 335 | * @since 2.3.4 |
| 336 | 336 | * |
@@ -381,7 +381,7 @@ discard block |
||
| 381 | 381 | /** |
| 382 | 382 | * Move onto the next Iterator row |
| 383 | 383 | * |
| 384 | - * @return void|boolean |
|
| 384 | + * @return null|false |
|
| 385 | 385 | * |
| 386 | 386 | * @since 2.3.4 |
| 387 | 387 | * |
@@ -476,7 +476,7 @@ discard block |
||
| 476 | 476 | * Return field array from a Pod, a field's data, or a field option |
| 477 | 477 | * |
| 478 | 478 | * @param null $field |
| 479 | - * @param null $option |
|
| 479 | + * @param string $option |
|
| 480 | 480 | * |
| 481 | 481 | * @return bool|mixed |
| 482 | 482 | * |
@@ -1975,7 +1975,6 @@ discard block |
||
| 1975 | 1975 | * Return the next item ID, loops at the first id to return the last |
| 1976 | 1976 | * |
| 1977 | 1977 | * @param int $id |
| 1978 | - * @param array $find_params |
|
| 1979 | 1978 | * |
| 1980 | 1979 | * @return int |
| 1981 | 1980 | * @since 2.0 |
@@ -2491,7 +2490,7 @@ discard block |
||
| 2491 | 2490 | * @param null|int $offset Offset of rows |
| 2492 | 2491 | * @param null|int $total Total rows |
| 2493 | 2492 | * |
| 2494 | - * @return int Number of pages |
|
| 2493 | + * @return double Number of pages |
|
| 2495 | 2494 | * @since 2.3.10 |
| 2496 | 2495 | */ |
| 2497 | 2496 | public function total_pages( $limit = null, $offset = null, $total = null ) { |
@@ -2600,7 +2599,7 @@ discard block |
||
| 2600 | 2599 | * @see PodsAPI::save_pod_item |
| 2601 | 2600 | * |
| 2602 | 2601 | * @param string $field Field name |
| 2603 | - * @param mixed $value ID(s) to add, int|float to add to number field, string for dates (+1 week), or string for text |
|
| 2602 | + * @param string $value ID(s) to add, int|float to add to number field, string for dates (+1 week), or string for text |
|
| 2604 | 2603 | * @param int $id (optional) ID of the pod item to update |
| 2605 | 2604 | * |
| 2606 | 2605 | * @return int The item ID |
@@ -2711,7 +2710,7 @@ discard block |
||
| 2711 | 2710 | * @see PodsAPI::save_pod_item |
| 2712 | 2711 | * |
| 2713 | 2712 | * @param string $field Field name |
| 2714 | - * @param mixed $value ID(s) to add, int|float to add to number field, string for dates (-1 week), or string for text |
|
| 2713 | + * @param string $value ID(s) to add, int|float to add to number field, string for dates (-1 week), or string for text |
|
| 2715 | 2714 | * @param int $id (optional) ID of the pod item to update |
| 2716 | 2715 | * |
| 2717 | 2716 | * @return int The item ID |
@@ -3321,7 +3320,7 @@ discard block |
||
| 3321 | 3320 | * |
| 3322 | 3321 | * @see Pods_Templates::template |
| 3323 | 3322 | * |
| 3324 | - * @param string $template The template name |
|
| 3323 | + * @param string $template_name The template name |
|
| 3325 | 3324 | * @param string $code Custom template code to use instead |
| 3326 | 3325 | * @param bool $deprecated Whether to use deprecated functionality based on old function usage |
| 3327 | 3326 | * |
@@ -3607,7 +3606,6 @@ discard block |
||
| 3607 | 3606 | * Replace magic tags with their values |
| 3608 | 3607 | * |
| 3609 | 3608 | * @param string $code The content to evaluate |
| 3610 | - * @param object $obj The Pods object |
|
| 3611 | 3609 | * |
| 3612 | 3610 | * @return string Code with Magic Tags evaluated |
| 3613 | 3611 | * |
@@ -3621,7 +3619,6 @@ discard block |
||
| 3621 | 3619 | * Replace magic tags with their values |
| 3622 | 3620 | * |
| 3623 | 3621 | * @param string $tag The magic tag to process |
| 3624 | - * @param object $obj The Pods object |
|
| 3625 | 3622 | * |
| 3626 | 3623 | * @return string Code with Magic Tags evaluated |
| 3627 | 3624 | * |
@@ -18,7 +18,7 @@ discard block |
||
| 18 | 18 | /** |
| 19 | 19 | * Return array of valid frontier type shortcode tags |
| 20 | 20 | * |
| 21 | - * @return array |
|
| 21 | + * @return string[] |
|
| 22 | 22 | */ |
| 23 | 23 | function frontier_get_shortcodes() { |
| 24 | 24 | $shortcodes = array( 'each', 'pod_sub_template', 'once', 'pod_once_template', 'before', 'pod_before_template', 'after', 'pod_after_template', 'if', 'pod_if_field' ); |
@@ -239,7 +239,7 @@ discard block |
||
| 239 | 239 | * @param array attributes from template |
| 240 | 240 | * @param string template to be processed |
| 241 | 241 | * |
| 242 | - * @return null |
|
| 242 | + * @return string |
|
| 243 | 243 | * @since 2.4 |
| 244 | 244 | */ |
| 245 | 245 | function frontier_do_subtemplate( $atts, $content ) { |
@@ -2555,7 +2555,7 @@ discard block |
||
| 2555 | 2555 | * |
| 2556 | 2556 | * @param PodsUI $ui |
| 2557 | 2557 | * |
| 2558 | - * @return bool |
|
| 2558 | + * @return boolean|null |
|
| 2559 | 2559 | */ |
| 2560 | 2560 | public function admin_components_toggle ( PodsUI $ui ) { |
| 2561 | 2561 | $component = $_GET[ 'id' ]; |
@@ -2688,7 +2688,7 @@ discard block |
||
| 2688 | 2688 | * |
| 2689 | 2689 | * @param $capabilities List of extra capabilities to add |
| 2690 | 2690 | * |
| 2691 | - * @return array |
|
| 2691 | + * @return string[] |
|
| 2692 | 2692 | */ |
| 2693 | 2693 | public function admin_capabilities ( $capabilities ) { |
| 2694 | 2694 | $pods = pods_api()->load_pods( array( 'type' => array( 'settings', 'post_type', 'taxonomy' ), 'fields' => false, 'table_info' => false ) ); |
@@ -3029,7 +3029,7 @@ discard block |
||
| 3029 | 3029 | * |
| 3030 | 3030 | * @param array $pod |
| 3031 | 3031 | * |
| 3032 | - * @return bool |
|
| 3032 | + * @return boolean|null |
|
| 3033 | 3033 | */ |
| 3034 | 3034 | protected function restable_pod( $pod ) { |
| 3035 | 3035 | |