diff --git a/src/wp-admin/includes/taxonomy.php b/src/wp-admin/includes/taxonomy.php
index 2326e9eb50..18d711b116 100644
a
|
b
|
function wp_insert_category( $catarr, $wp_error = false ) { |
186 | 186 | * @return int|false The ID number of the new or updated Category on success. Zero or FALSE on failure. |
187 | 187 | */ |
188 | 188 | function wp_update_category( $catarr ) { |
189 | | $cat_ID = (int) $catarr['cat_ID']; |
| 189 | $cat_id = (int) $catarr['cat_ID']; |
190 | 190 | |
191 | | if ( isset( $catarr['category_parent'] ) && ( $cat_ID == $catarr['category_parent'] ) ) { |
192 | | return false; |
| 191 | // Check that cat_id isset and not empty. |
| 192 | if( isset( $cat_id ) && !empty( $cat_id ) ) { |
| 193 | if ( isset( $catarr['category_parent'] ) && ( $cat_id == $catarr['category_parent'] ) ) { |
| 194 | return false; |
| 195 | } |
193 | 196 | } |
194 | | |
| 197 | |
195 | 198 | // First, get all of the original fields. |
196 | | $category = get_term( $cat_ID, 'category', ARRAY_A ); |
| 199 | $category = get_term( $cat_id, 'category', ARRAY_A ); |
197 | 200 | _make_cat_compat( $category ); |
198 | 201 | |
199 | 202 | // Escape data pulled from DB. |
diff --git a/src/wp-admin/includes/user.php b/src/wp-admin/includes/user.php
index 134da30514..284084c09c 100644
a
|
b
|
Please click the following link to activate your user account: |
621 | 621 | function wp_is_authorize_application_password_request_valid( $request, $user ) { |
622 | 622 | $error = new WP_Error(); |
623 | 623 | |
| 624 | // Check that $request is empty ot not. |
624 | 625 | if ( ! empty( $request['success_url'] ) ) { |
625 | 626 | $scheme = wp_parse_url( $request['success_url'], PHP_URL_SCHEME ); |
626 | 627 | |
… |
… |
function wp_is_authorize_application_password_request_valid( $request, $user ) { |
632 | 633 | } |
633 | 634 | } |
634 | 635 | |
| 636 | // Check that $request is empty ot not. |
635 | 637 | if ( ! empty( $request['reject_url'] ) ) { |
636 | 638 | $scheme = wp_parse_url( $request['reject_url'], PHP_URL_SCHEME ); |
637 | 639 | |
… |
… |
function wp_is_authorize_application_password_request_valid( $request, $user ) { |
643 | 645 | } |
644 | 646 | } |
645 | 647 | |
| 648 | // Check that $request is empty ot not and check that app id is uuid or not. |
646 | 649 | if ( ! empty( $request['app_id'] ) && ! wp_is_uuid( $request['app_id'] ) ) { |
647 | 650 | $error->add( |
648 | 651 | 'invalid_app_id', |