Skip to content

Commit

Permalink
explat: Fix Phan issues (#39443)
Browse files Browse the repository at this point in the history
Add some missing `use` directives and add `WP_Error` to one return
declaration.

Committed via a GitHub action: https://github.com/Automattic/jetpack/actions/runs/11238483186

Upstream-Ref: Automattic/jetpack@afd13ad
  • Loading branch information
anomiex authored and matticbot committed Oct 8, 2024
1 parent c983b92 commit e4c4e8e
Show file tree
Hide file tree
Showing 5 changed files with 66 additions and 64 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
use Automattic\Jetpack\Connection\Client;
use Automattic\Jetpack\Connection\Manager as Jetpack_Connection;
use WP_Error;
use WP_REST_Request;
use WP_REST_Response;
use WP_REST_Server;

/**
Expand Down Expand Up @@ -71,7 +73,7 @@ public function register_rest_routes() {
* Get the assignments for a given experiment and anon_id
*
* @param WP_REST_Request $request The REST request object.
* @return WP_REST_Response
* @return WP_REST_Response|WP_Error
*/
public function get_assignments( $request ) {
$response = null;
Expand Down
2 changes: 1 addition & 1 deletion jetpack_vendor/i18n-map.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
),
'jetpack-explat' => array(
'path' => 'jetpack_vendor/automattic/jetpack-explat',
'ver' => '0.1.11-alpha1728387153',
'ver' => '0.1.11-alpha1728400476',
),
'jetpack-ip' => array(
'path' => 'jetpack_vendor/automattic/jetpack-ip',
Expand Down
60 changes: 30 additions & 30 deletions vendor/composer/installed.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-a8c-mc-stats",
"reference": "c95ac3cc76d4eda4be0142ff71b6b0e9bd08b4ce"
"reference": "f90a7ec9c40ccc8c9fc4cb364f1549a4bf5bc128"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -60,7 +60,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-admin-ui",
"reference": "cc085210020bdf73e14b7c2b75581828cb0453dc"
"reference": "07e0255e29b1fa680a5f35ab5050953ad7498da7"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -125,7 +125,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-assets",
"reference": "5e83a9da74a48cf8a4dd276d347537bbd6eb683c"
"reference": "33d447406e0b295bbd857f19ce31c461afd4f5a5"
},
"require": {
"automattic/jetpack-constants": "^2.0.4",
Expand Down Expand Up @@ -194,7 +194,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-autoloader",
"reference": "634dc42a3b5a18185055690c347d1a1cf25239c5"
"reference": "34edc7be6472908456eb41ed216b74f4a823049d"
},
"require": {
"composer-plugin-api": "^1.1 || ^2.0",
Expand Down Expand Up @@ -261,7 +261,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-boost-core",
"reference": "9aabc6d2a9bce7308831888c0aeda49998db9819"
"reference": "2ae84c071ecaca6e8e3f177759ad001c5c4dce89"
},
"require": {
"automattic/jetpack-connection": "^5.1.2",
Expand Down Expand Up @@ -329,7 +329,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-boost-speed-score",
"reference": "f3c515fdcf3cf27d74155034bfadc38dc5ba5b55"
"reference": "058b186e05bf9db5221ca1a4eb61666e47e12dbc"
},
"require": {
"automattic/jetpack-boost-core": "^0.2.12",
Expand Down Expand Up @@ -405,7 +405,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-composer-plugin",
"reference": "3676057cb6c9ad428632af8bb3633068ba1d98d9"
"reference": "cb598af47a5ddeab84994bf40e8c94d6cc5aaa8b"
},
"require": {
"composer-plugin-api": "^2.1.0",
Expand Down Expand Up @@ -465,7 +465,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-config",
"reference": "e325bec9f1bd16e897a38fae48fea71e23592e5c"
"reference": "07af7f444ef9d97b95f946605aa23626f00df29e"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -540,7 +540,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-connection",
"reference": "f29c0f3f1e10d90948de969966d19aec6849207c"
"reference": "9c0df43970d36693a2b59ad78edc67b11d82c81f"
},
"require": {
"automattic/jetpack-a8c-mc-stats": "^2.0.3",
Expand Down Expand Up @@ -630,7 +630,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-constants",
"reference": "04657668ac9feb729898628c9a1f155ed33539c4"
"reference": "c35e0f759039217a16a111d635249ab74a0b6418"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -684,7 +684,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-device-detection",
"reference": "5ce5f4804478d0dd5b92bd53e371755136e1a2c6"
"reference": "e8588aed125a831b38c3cca130fba8863734c485"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -732,12 +732,12 @@
},
{
"name": "automattic/jetpack-explat",
"version": "0.1.11-alpha.1728387153",
"version_normalized": "0.1.11.0-alpha1728387153",
"version": "0.1.11-alpha.1728400476",
"version_normalized": "0.1.11.0-alpha1728400476",
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-explat",
"reference": "f384605b83840068ec1a1b0f817635103603fc1d"
"reference": "cee9013d32f347edfa3b14c9fb40bb14f1f460c0"
},
"require": {
"automattic/jetpack-connection": "^5.1.2",
Expand Down Expand Up @@ -812,7 +812,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-ip",
"reference": "73798eeb3e671a1779b8f44aa4e6db0f8f93b32c"
"reference": "6930a41ba888616de90cfe0f8eae1facb8f8565f"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -870,7 +870,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-jitm",
"reference": "1e39e8653bcde1663eba25d699506db3a587eab7"
"reference": "ff0382f3fe04824f4de0fb79c1a37b4b4ece998a"
},
"require": {
"automattic/jetpack-a8c-mc-stats": "^2.0.3",
Expand Down Expand Up @@ -945,7 +945,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-licensing",
"reference": "9c80c166bbacc1e9029cb1a7fd6fc30c9bbc0d6b"
"reference": "befbe9e187f937b1ec6b2074e20f84ed0e9f87a4"
},
"require": {
"automattic/jetpack-connection": "^5.1.2",
Expand Down Expand Up @@ -1007,7 +1007,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-logo",
"reference": "31af489c39f03a1a769d78384374ac5db9650621"
"reference": "538a0e30838ba0e0011636a50c38efca92104e2a"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -1060,7 +1060,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-my-jetpack",
"reference": "2a3dd982485a990f1025eb707b5e96278a736fa1"
"reference": "721dec9087fc019f715b83b50f76a1c1ef3fba47"
},
"require": {
"automattic/jetpack-admin-ui": "^0.4.5",
Expand Down Expand Up @@ -1162,7 +1162,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-password-checker",
"reference": "2fdc4680bd21ee4bfc3d09266f7723fec0e6b4f3"
"reference": "812a19a22e82bbd9d50d724cd5d42f6512528d04"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -1223,7 +1223,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-plans",
"reference": "1697cafbd928dda6400f36e311767ab315fd2914"
"reference": "b04aa10e96a46d8fdbc117c197258989766b1d62"
},
"require": {
"automattic/jetpack-connection": "^5.1.2",
Expand Down Expand Up @@ -1291,7 +1291,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-plugins-installer",
"reference": "8a5cbc27e64681a849d82fca2f493c19a2a61193"
"reference": "29b2a3a94304ae78c69ec2ccb6d8c848d597307e"
},
"require": {
"automattic/jetpack-a8c-mc-stats": "^2.0.3",
Expand Down Expand Up @@ -1347,7 +1347,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-protect-models",
"reference": "abbae680aa6b75bac341e5db81a5216bbdd2a124"
"reference": "6e6c096da3f96a874ea37aa602c27434e9330993"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -1417,7 +1417,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-protect-status",
"reference": "91a0d4d85f9972e6cc5bfd03f2a203ae24337bc9"
"reference": "e9849fcc31ffbaf96165ae892b2571c6cd4a08e6"
},
"require": {
"automattic/jetpack-connection": "^5.1.2",
Expand Down Expand Up @@ -1492,7 +1492,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-redirect",
"reference": "e6b334b2e58f191443db341f6c82814b844f19a3"
"reference": "5651956398346db34390b6919c0e88cf4db0addb"
},
"require": {
"automattic/jetpack-status": "^4.0.2",
Expand Down Expand Up @@ -1547,7 +1547,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-roles",
"reference": "b34b170ce4ea680c37ef7febea2d0e389fa59d17"
"reference": "3efe6601e35d11e8069d27d57ad6da0c3987f3df"
},
"require": {
"php": ">=7.0"
Expand Down Expand Up @@ -1601,7 +1601,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-search",
"reference": "dc0bdd8a3bd9994e3528bba9fef3a6071a4e7351"
"reference": "0c9dfeee211c520a5f713c126a86af80e1c7f8ba"
},
"require": {
"automattic/jetpack-assets": "^2.3.9",
Expand Down Expand Up @@ -1689,7 +1689,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-stats",
"reference": "e4fec787a573d0c6abcc5f5cfbad0384619a4a6b"
"reference": "573c721fe6d5d05c5f03059e705944f2cb22090e"
},
"require": {
"automattic/jetpack-connection": "^5.1.2",
Expand Down Expand Up @@ -1756,7 +1756,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-status",
"reference": "95009c4857264e414e75307d3e5b94c8f1d7ce8d"
"reference": "08c127be504779565ae8f65bb71f95f1a925db50"
},
"require": {
"automattic/jetpack-constants": "^2.0.4",
Expand Down Expand Up @@ -1820,7 +1820,7 @@
"dist": {
"type": "path",
"url": "/tmp/jetpack-build/Automattic/jetpack-sync",
"reference": "e557167a6c5ebeaef22bbd5614e4b20e1c404ecc"
"reference": "3e782ce42e6896619799c534eb8d8218c582ff8b"
},
"require": {
"automattic/jetpack-connection": "^5.1.2",
Expand Down
Loading

0 comments on commit e4c4e8e

Please sign in to comment.