From 703d474e529681e087167c06a59ed73f3ed7637e Mon Sep 17 00:00:00 2001 From: Ido F Date: Mon, 14 Dec 2020 13:31:52 +0200 Subject: [PATCH 1/2] corrected data-types in phpdoc @param --- .../data-stores/class-wc-coupon-data-store-cpt.php | 2 +- .../data-stores/class-wc-payment-token-data-store.php | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/includes/data-stores/class-wc-coupon-data-store-cpt.php b/includes/data-stores/class-wc-coupon-data-store-cpt.php index 8f9b7310144..24e2b7139a4 100644 --- a/includes/data-stores/class-wc-coupon-data-store-cpt.php +++ b/includes/data-stores/class-wc-coupon-data-store-cpt.php @@ -427,7 +427,7 @@ class WC_Coupon_Data_Store_CPT extends WC_Data_Store_WP implements WC_Coupon_Dat * * @since 3.0.0 * @param WC_Coupon $coupon Coupon object. - * @param id $user_id User ID. + * @param int $user_id User ID. * @return int */ public function get_usage_by_user_id( &$coupon, $user_id ) { diff --git a/includes/data-stores/class-wc-payment-token-data-store.php b/includes/data-stores/class-wc-payment-token-data-store.php index 81e22115056..412f92bd1c9 100644 --- a/includes/data-stores/class-wc-payment-token-data-store.php +++ b/includes/data-stores/class-wc-payment-token-data-store.php @@ -305,7 +305,7 @@ class WC_Payment_Token_Data_Store extends WC_Data_Store_WP implements WC_Payment * Should contain the fields token_id, gateway_id, token, user_id, type, is_default. * * @since 3.0.0 - * @param id $token_id Token ID. + * @param mixed $token_id Token ID. * @return object */ public function get_token_by_id( $token_id ) { @@ -322,7 +322,7 @@ class WC_Payment_Token_Data_Store extends WC_Data_Store_WP implements WC_Payment * Returns metadata for a specific payment token. * * @since 3.0.0 - * @param id $token_id Token ID. + * @param mixed $token_id Token ID. * @return array */ public function get_metadata( $token_id ) { @@ -333,7 +333,7 @@ class WC_Payment_Token_Data_Store extends WC_Data_Store_WP implements WC_Payment * Get a token's type by ID. * * @since 3.0.0 - * @param id $token_id Token ID. + * @param mixed $token_id Token ID. * @return string */ public function get_token_type_by_id( $token_id ) { @@ -353,8 +353,8 @@ class WC_Payment_Token_Data_Store extends WC_Data_Store_WP implements WC_Payment * * @since 3.0.0 * - * @param id $token_id Token ID. - * @param bool $status Whether given payment token is the default payment token or not. + * @param mixed $token_id Token ID. + * @param bool $status Whether given payment token is the default payment token or not. * * @return void */ From 4be88bea4b6362195f3e669b8c4a77c4545dd9fd Mon Sep 17 00:00:00 2001 From: Ido F Date: Sun, 10 Jan 2021 16:40:24 +0200 Subject: [PATCH 2/2] corrected token-id data-type --- .../data-stores/class-wc-payment-token-data-store.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/includes/data-stores/class-wc-payment-token-data-store.php b/includes/data-stores/class-wc-payment-token-data-store.php index 412f92bd1c9..78ea7272dcb 100644 --- a/includes/data-stores/class-wc-payment-token-data-store.php +++ b/includes/data-stores/class-wc-payment-token-data-store.php @@ -305,7 +305,7 @@ class WC_Payment_Token_Data_Store extends WC_Data_Store_WP implements WC_Payment * Should contain the fields token_id, gateway_id, token, user_id, type, is_default. * * @since 3.0.0 - * @param mixed $token_id Token ID. + * @param int $token_id Token ID. * @return object */ public function get_token_by_id( $token_id ) { @@ -322,7 +322,7 @@ class WC_Payment_Token_Data_Store extends WC_Data_Store_WP implements WC_Payment * Returns metadata for a specific payment token. * * @since 3.0.0 - * @param mixed $token_id Token ID. + * @param int $token_id Token ID. * @return array */ public function get_metadata( $token_id ) { @@ -333,7 +333,7 @@ class WC_Payment_Token_Data_Store extends WC_Data_Store_WP implements WC_Payment * Get a token's type by ID. * * @since 3.0.0 - * @param mixed $token_id Token ID. + * @param int $token_id Token ID. * @return string */ public function get_token_type_by_id( $token_id ) { @@ -353,8 +353,8 @@ class WC_Payment_Token_Data_Store extends WC_Data_Store_WP implements WC_Payment * * @since 3.0.0 * - * @param mixed $token_id Token ID. - * @param bool $status Whether given payment token is the default payment token or not. + * @param int $token_id Token ID. + * @param bool $status Whether given payment token is the default payment token or not. * * @return void */