MCPcopy Create free account
hub / github.com/taskforcesh/bullmq / flatHashToArray

Method flatHashToArray

php/src/Queue.php:363–373  ·  view source on GitHub ↗

* Convert a flat Redis HGETALL response into an associative array. * * @param array $flatHash * @return array */

(array $flatHash)

Source from the content-addressed store, hash-verified

361 * @return array<string, mixed>
362 */
363 private function flatHashToArray(array $flatHash): array
364 {
365 $rawData = [];
366 $count = count($flatHash);
367
368 for ($i = 0; $i < $count - 1; $i += 2) {
369 $rawData[(string) $flatHash[$i]] = $flatHash[$i + 1];
370 }
371
372 return $rawData;
373 }
374
375 /**
376 * Get waiting jobs.

Callers 1

getJobsByTypeMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected