]> git.mxchange.org Git - hub.git/blobdiff - application/hub/main/dht/node/class_NodeDhtFacade.php
Expanded debug lines, renamed 'node_type' to 'node_mode' (which makes your DHT databa...
[hub.git] / application / hub / main / dht / node / class_NodeDhtFacade.php
index 30709fb4c770436e5084a8337cbe32ef866569a8..9c00f7127600d601f11f9e1b91e58ba36062aff1 100644 (file)
@@ -224,11 +224,16 @@ class NodeDhtFacade extends BaseDht implements Distributable, Registerable {
                // Get node list
                $nodeList = array();
                while ($resultInstance->next()) {
+                       // Get current element (it should be an array, and have at least 1 entry)
+                       $current = $resultInstance->current();
+                       assert(is_array($current));
+                       assert(count($current) > 0);
+
                        // Debug message
-                       /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('DHT-FACADE[' . __LINE__ . ']: current()=' . $resultInstance->current());
+                       /* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput('DHT-FACADE[' . __LINE__ . ']: current(' . count($current) . ')[' . gettype($current) . ']=' . print_r($current, TRUE));
 
                        // Add this entry
-                       array_push($nodeList, $resultInstance->current());
+                       array_push($nodeList, $current);
                } // END - while
 
                // Save last exception