From 31b73ae1a8b353111f3cc6ab8d20522aabdad5ec Mon Sep 17 00:00:00 2001 From: Ryan Rondeau Date: Thu, 19 Dec 2024 15:09:37 -0800 Subject: [PATCH] feat: Release 0.6.11 (#837) Co-authored-by: afwilcox Co-authored-by: jon-funk Co-authored-by: Derek Roberts Co-authored-by: Scarlett <35635257+Scarlett-Truong@users.noreply.github.com> Co-authored-by: dmitri-korin-bcps <108112696+dmitri-korin-bcps@users.noreply.github.com> --- backend/src/v1/complaint/complaint.service.ts | 1 - .../app/components/containers/complaints/complaint-list.tsx | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/backend/src/v1/complaint/complaint.service.ts b/backend/src/v1/complaint/complaint.service.ts index af0be3b67..fbfaee64d 100644 --- a/backend/src/v1/complaint/complaint.service.ts +++ b/backend/src/v1/complaint/complaint.service.ts @@ -1000,7 +1000,6 @@ export class ComplaintService { token?: string, ): Promise => { try { - this.logger.error("Searching for complaints"); let results: SearchResults = { totalCount: 0, complaints: [] }; const { orderBy, sortBy, page, pageSize, query, ...filters } = model; diff --git a/frontend/src/app/components/containers/complaints/complaint-list.tsx b/frontend/src/app/components/containers/complaints/complaint-list.tsx index e7558252f..ab853540c 100644 --- a/frontend/src/app/components/containers/complaints/complaint-list.tsx +++ b/frontend/src/app/components/containers/complaints/complaint-list.tsx @@ -1,4 +1,4 @@ -import { FC, useRef, useState, useContext, useEffect } from "react"; +import { FC, useRef, useState, useContext, useEffect, useCallback } from "react"; import { useAppDispatch, useAppSelector } from "@hooks/hooks"; import COMPLAINT_TYPES from "@apptypes/app/complaint-types"; import { @@ -173,10 +173,10 @@ export const ComplaintList: FC = ({ type, searchQuery }) => { } }; - const handlePageChange = (page: number) => { + const handlePageChange = useCallback((page: number) => { setPage(page); scrollToTop(); - }; + }, []); // Scroll to top of table container when paginating const divRef = useRef(null);