Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Merge branch 'main' into refactor-download-manager

Abhinav2765df754726
diff --cc apps/photos/src/components/PhotoFrame.tsx
index 4a37bb6bad,c4f689f1b9..ddaa85d50b
--- a/apps/photos/src/components/PhotoFrame.tsx
+++ b/apps/photos/src/components/PhotoFrame.tsx
@@@ -8,8 -8,8 +8,7 @@@ import AutoSizer from 'react-virtualize
import PhotoViewer from 'components/PhotoViewer';
import { TRASH_SECTION } from 'constants/collection';
import { updateFileMsrcProps, updateFileSrcProps } from 'utils/photoFrame';
- import { PhotoList } from './PhotoList';
import { MergedSourceURL, SelectedState } from 'types/gallery';
-import PublicCollectionDownloadManager from 'services/publicCollectionDownloadManager';
import { PublicCollectionGalleryContext } from 'utils/publicCollectionGallery';
import { useRouter } from 'next/router';
import { logError } from '@ente/shared/sentry';
diff --cc apps/photos/src/utils/billing/index.ts
index 056fe66121,4e62a5d770..b970d70082
--- a/apps/photos/src/utils/billing/index.ts
+++ b/apps/photos/src/utils/billing/index.ts
@@@ -140,11 -140,12 +140,14 @@@ export function hasMobileSubscription(s
}
export function hasExceededStorageQuota(userDetails: UserDetails) {
+ const bonusStorage = userDetails.storageBonus ?? 0;
if (isPartOfFamily(userDetails.familyData)) {
const usage = getTotalFamilyUsage(userDetails.familyData);
- return usage > userDetails.familyData.storage;
- return usage > (userDetails.familyData.storage + bonusStorage);
++ return usage > userDetails.familyData.storage + bonusStorage;
} else {
- return userDetails.usage > userDetails.subscription.storage;
- return userDetails.usage > (userDetails.subscription.storage + bonusStorage);
++ return (
++ userDetails.usage > userDetails.subscription.storage + bonusStorage
++ );
}
}
diff --cc packages/shared/error/index.ts
index 0887fe12bf,68fa970641..305d88fa7d
--- a/packages/shared/error/index.ts
+++ b/packages/shared/error/index.ts
@@@ -86,7 -86,8 +86,9 @@@ export const CustomError =
ServerError: 'server error',
FILE_NOT_FOUND: 'file not found',
UNSUPPORTED_PLATFORM: 'Unsupported platform',
+ MODEL_DOWNLOAD_PENDING:
+ 'Model download pending, skipping clip search request',
+ DOWNLOAD_MANAGER_NOT_READY: 'Download manager not initialized',
};
export function handleUploadError(error: any): Error {