From 1620ea26253712ad41bb96ff37b0bf075c7cd466 Mon Sep 17 00:00:00 2001 From: Brock Fanning <1319083+brockfanning@users.noreply.github.com> Date: Wed, 3 Jun 2026 17:31:09 +0000 Subject: [PATCH 1/2] FOIA-545: Remove debugging. --- js/stores/agency_component.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/js/stores/agency_component.js b/js/stores/agency_component.js index f44c2b15..9b3f5fc7 100644 --- a/js/stores/agency_component.js +++ b/js/stores/agency_component.js @@ -80,11 +80,9 @@ class AgencyComponentStore extends Store { // Count up the agency's num_requests total from components. let numRequests = 0; this.getAgencyComponentsForAgency(agency.id).forEach((component) => { - console.log('Component - ' + component.title + ' num_requests: ' + component.num_requests); numRequests += parseInt(component?.num_requests, 10) || 0; }); // Add a title and num_requests property for common displayKey - console.log('Agency - ' + agency.name + ' num_requests: ' + numRequests); return { ...agency.toJS(), title: agency.name, From 23def792082a58ef4bfcfa41a3ee7f92f70aee4d Mon Sep 17 00:00:00 2001 From: Brock Fanning <1319083+brockfanning@users.noreply.github.com> Date: Wed, 3 Jun 2026 17:49:22 +0000 Subject: [PATCH 2/2] FOIA-545: Linting fixes. --- js/stores/agency_component.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/js/stores/agency_component.js b/js/stores/agency_component.js index 9b3f5fc7..a925fe2a 100644 --- a/js/stores/agency_component.js +++ b/js/stores/agency_component.js @@ -80,7 +80,9 @@ class AgencyComponentStore extends Store { // Count up the agency's num_requests total from components. let numRequests = 0; this.getAgencyComponentsForAgency(agency.id).forEach((component) => { - numRequests += parseInt(component?.num_requests, 10) || 0; + if (component.num_requests) { + numRequests += parseInt(component.num_requests, 10) || 0; + } }); // Add a title and num_requests property for common displayKey return {