Skip to content

Commit

Permalink
Replace isLoading with shouldShowSkeleton in shouldShowNotFoundPage
Browse files Browse the repository at this point in the history
  • Loading branch information
roryabraham committed Mar 25, 2024
1 parent e55b82d commit 6873f24
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/pages/home/ReportScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ function ReportScreen({
// eslint-disable-next-line rulesdir/no-negated-variables
const shouldShowNotFoundPage = useMemo(
(): boolean =>
!isLoading &&
!shouldShowSkeleton &&
((!wasReportAccessibleRef.current &&
!firstRenderRef.current &&
!report.reportID &&
Expand All @@ -350,7 +350,7 @@ function ReportScreen({
!userLeavingStatus) ||
shouldHideReport ||
(!!reportIDFromRoute && !ReportUtils.isValidReportIDFromPath(reportIDFromRoute))),
[report, reportMetadata, isLoading, shouldHideReport, isOptimisticDelete, userLeavingStatus, reportIDFromRoute],
[shouldShowSkeleton, report.reportID, isOptimisticDelete, reportMetadata?.isLoadingInitialReportActions, userLeavingStatus, shouldHideReport, reportIDFromRoute],
);

const fetchReport = useCallback(() => {
Expand Down

0 comments on commit 6873f24

Please sign in to comment.