From bf6ec12d8502ab7328799743cc35573a85fe0768 Mon Sep 17 00:00:00 2001 From: Christian Burk Date: Mon, 24 Jun 2024 16:29:32 -0500 Subject: [PATCH] VACMS-18380: Adds comments. --- docroot/modules/custom/va_gov_migrate/src/Commands/Commands.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docroot/modules/custom/va_gov_migrate/src/Commands/Commands.php b/docroot/modules/custom/va_gov_migrate/src/Commands/Commands.php index 938390ebdc..641b72814f 100644 --- a/docroot/modules/custom/va_gov_migrate/src/Commands/Commands.php +++ b/docroot/modules/custom/va_gov_migrate/src/Commands/Commands.php @@ -146,6 +146,7 @@ public function cleanRevs() { */ public function flagMissingFacilities() { $facilities_in_fapi = $this->getFapiList(); + // Make the two-dimensional array one dimension. $facilities_flat = array_reduce($facilities_in_fapi, function ($carry, $item) { return array_merge($carry, $item); }, []); @@ -292,6 +293,7 @@ protected function getFapiList(): array { $facility_migration = Migration::load('va_node_health_care_local_facility'); if ($facility_migration) { $source = $facility_migration->get('source'); + // We can only get a 1000 facilities at a time, so need to loop through. foreach ($source['urls'] as $url) { $headers = $source['headers']; $fetcher = $this->dataFetcherPluginManager->createInstance('http', ['headers' => $headers]);