Skip to content

GYR1-1166 Fix for extra query in ClientsController - #6425

Open
spompea-cfa wants to merge 5 commits into
mainfrom
gyr1-1166-clientscontroller-query-fix-and-remove-archived-logic
Open

GYR1-1166 Fix for extra query in ClientsController#6425
spompea-cfa wants to merge 5 commits into
mainfrom
gyr1-1166-clientscontroller-query-fix-and-remove-archived-logic

Conversation

@spompea-cfa

@spompea-cfa spompea-cfa commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

Link to Jira issue

Is PM acceptance required?

  • No

What was done?

The initial issue was that logic in the HubClientPresenter#initialize would grab
an intake from related_models_cache (so far so good) but subsequent logic
(having to do with archived intakes) resulted in client.intake being called
anyway (extra query) and the related_models_cache item not being used.

In ClientsController:

  • Modified some logic inside HubClientPresenter#initialize
  • Note: Added a small fix in how related_models_cache is accessed (need to
    have .first at the end)

How to test?

I would suggest briefly smoke testing the Hub Clients page.

@github-actions

Copy link
Copy Markdown

Heroku app: https://gyr-review-app-6425-a656b92ca442.herokuapp.com/
View logs: heroku logs --app gyr-review-app-6425 (optionally add --tail)

@spompea-cfa spompea-cfa changed the title GYR1-1166 GYR1-1166 ClientsController fix to alleviate extraneous query + remove legacy archived intake logic Aug 31, 2026
@spompea-cfa
spompea-cfa force-pushed the gyr1-1166-clientscontroller-query-fix-and-remove-archived-logic branch from 50eaa0b to cf80d94 Compare September 1, 2026 21:53
@spompea-cfa spompea-cfa changed the title GYR1-1166 ClientsController fix to alleviate extraneous query + remove legacy archived intake logic GYR1-1166 Fix for extra query in ClientsController Sep 1, 2026
@spompea-cfa
spompea-cfa marked this pull request as ready for review September 1, 2026 22:14
Comment thread app/controllers/hub/clients_controller.rb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant