Fix any type usage in proprietary/ (#5949)

# Description of Changes
Follow on from #5934, expanding `any` type usage ban to the
`proprietary/` folder
This commit is contained in:
James Brunton
2026-04-01 08:21:26 +00:00
committed by GitHub
parent a96b95e198
commit c31e4253dd
34 changed files with 341 additions and 266 deletions
@@ -1,4 +1,5 @@
import { useEffect, useMemo, useRef } from 'react';
import { isAxiosError } from 'axios';
import { useNavigate } from 'react-router-dom';
import { useTranslation } from 'react-i18next';
import apiClient from '@app/services/apiClient';
@@ -99,7 +100,7 @@ export default function ShareLinkLoader({ token }: ShareLinkLoaderProps) {
const idMap = new Map<string, FileId>();
for (let i = 0; i < stirlingFiles.length; i += 1) {
idMap.set(sortedEntries[i].logicalId, stirlingFiles[i].fileId as FileId);
idMap.set(sortedEntries[i].logicalId, stirlingFiles[i].fileId);
}
const rootIdMap = new Map<string, FileId>();
@@ -199,9 +200,9 @@ export default function ShareLinkLoader({ token }: ShareLinkLoaderProps) {
navActions.setWorkbench('viewer');
navigate('/', { replace: true });
} catch (error: any) {
} catch (error: unknown) {
if (signal.aborted) return;
const status = error?.response?.status;
const status = isAxiosError(error) ? error.response?.status : undefined;
if (status === 401 || status === 403) {
if (!isAuthenticated && !authLoading) {
alert({