General: Continuing to work towards a passing PHP Compatibility scan.

This is a final pass to fix PHP compatibiilty issues in the codebase with code changes or adding `phpcs:ignore` comments.

With this change, all PHP compatibility warnings and errors without specific tickets have been addressed (see #49810 and #41750).

Props desrosj, johnbillion, jrf.
See #49922.

git-svn-id: https://develop.svn.wordpress.org/trunk@47902 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Jonathan Desrosiers
2020-06-03 17:38:56 +00:00
parent 2da8918f1a
commit dfccba8d55
11 changed files with 16 additions and 22 deletions
+2 -2
View File
@@ -290,8 +290,8 @@ function map_meta_cap( $cap, $user_id, ...$args ) {
case 'edit_user_meta':
case 'delete_user_meta':
case 'add_user_meta':
list( $_, $object_type, $_ ) = explode( '_', $cap );
$object_id = (int) $args[0];
$object_type = explode( '_', $cap )[1];
$object_id = (int) $args[0];
$object_subtype = get_object_subtype( $object_type, $object_id );