X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=application%2Fhub%2Fmain%2Fdiscovery%2Fpackage%2Fclass_PackageRecipientDiscovery.php;h=040c3083b65cf7e66da50295438ff3cfd85df532;hb=193e418fd76d06a69d5031b9702fa0c093c95cad;hp=5567d36ed280b68c6afa7794e2f4c7aa38f5bc76;hpb=20d457aab33983f395962b20590c0c6c12669a43;p=hub.git diff --git a/application/hub/main/discovery/package/class_PackageRecipientDiscovery.php b/application/hub/main/discovery/package/class_PackageRecipientDiscovery.php index 5567d36ed..040c3083b 100644 --- a/application/hub/main/discovery/package/class_PackageRecipientDiscovery.php +++ b/application/hub/main/discovery/package/class_PackageRecipientDiscovery.php @@ -59,6 +59,9 @@ class PackageRecipientDiscovery extends BaseHubDiscovery implements Discoverable * @return void */ public function discoverRecipients (array $packageData) { + // This must be available + assert($packageData[NetworkPackage::PACKAGE_DATA_RECIPIENT]); + // First try out the direct recipient (session id) try { // Get instance (should not break) @@ -90,6 +93,9 @@ class PackageRecipientDiscovery extends BaseHubDiscovery implements Discoverable * @todo The if() does only check for TCP, not UDP, e.g. try to get a $handlerInstance here */ public function discoverRawRecipients (array $decodedData) { + // This must be available + assert($decodedData[NetworkPackage::PACKAGE_DATA_RECIPIENT]); + // First clear all recipients $this->clearRecipients();