From 5fad08eb8ddfd0e1a5677c442a5f5406a21f828d Mon Sep 17 00:00:00 2001 From: Arkadiusz Bachorski <60391032+arkadiuszbachorski@users.noreply.github.com> Date: Tue, 8 Oct 2024 16:45:50 +0200 Subject: [PATCH] Fix latest questionnaire date (#61) # Fix latest questionnaire date ### Code of Conduct & Contributing Guidelines By submitting creating this pull request, you agree to follow our [Code of Conduct](https://github.com/StanfordBDHG/.github/blob/main/CODE_OF_CONDUCT.md) and [Contributing Guidelines](https://github.com/StanfordBDHG/.github/blob/main/CONTRIBUTING.md): - [x] I agree to follow the [Code of Conduct](https://github.com/StanfordBDHG/.github/blob/main/CODE_OF_CONDUCT.md) and [Contributing Guidelines](https://github.com/StanfordBDHG/.github/blob/main/CONTRIBUTING.md). --- routes/~_dashboard/~patients/utils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/routes/~_dashboard/~patients/utils.ts b/routes/~_dashboard/~patients/utils.ts index d1a7054f..065ed833 100644 --- a/routes/~_dashboard/~patients/utils.ts +++ b/routes/~_dashboard/~patients/utils.ts @@ -224,7 +224,7 @@ export const getUserActivity = async ({ const latestQuestionnaires = await getDocsData( query( refs.questionnaireResponses({ resourceType, userId: authUser.uid }), - orderBy('authored'), + orderBy('authored', 'desc'), limit(1), ), )