Patient Portal in 6.1.0 (0) and 6.1.0 (1) slow to open

When first logging into the portal, there is a significant delay. I suspect the issue is in how documents are handled, but I am not sure how to fixt this. Patients will not like the delay and I would like to decrease the login time.

I added an index to the onsite_documents table for the field PID
Still testing, but open to other ideas.

OpenEMR Version
I’m using OpenEMR version 6.1.0 (1)

I’m using: Firefox & MS Edge

Operating System
I’m using: Ubuntu 20.04