From e84a8a58c762ed54bde22ee4dba584e248ba1015 Mon Sep 17 00:00:00 2001 From: tapframe Date: Sat, 25 Oct 2025 01:19:34 +0530 Subject: [PATCH] metadacrash fix --- src/components/home/DropUpMenu.tsx | 4 ++-- src/hooks/useMetadataAssets.ts | 2 ++ src/hooks/useUpdatePopup.ts | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/components/home/DropUpMenu.tsx b/src/components/home/DropUpMenu.tsx index fe70f35..3ee59ed 100644 --- a/src/components/home/DropUpMenu.tsx +++ b/src/components/home/DropUpMenu.tsx @@ -96,8 +96,8 @@ export const DropUpMenu = ({ visible, onClose, item, onOptionSelect, isSaved: is // Robustly determine if the item is in the library (saved) const isSaved = typeof isSavedProp === 'boolean' ? isSavedProp : !!item.inLibrary; const isWatched = !!isWatchedProp; - const inTraktWatchlist = isAuthenticated && isInWatchlist(item.id, item.type); - const inTraktCollection = isAuthenticated && isInCollection(item.id, item.type); + const inTraktWatchlist = isAuthenticated && isInWatchlist(item.id, item.type as 'movie' | 'show'); + const inTraktCollection = isAuthenticated && isInCollection(item.id, item.type as 'movie' | 'show'); let menuOptions = [ { diff --git a/src/hooks/useMetadataAssets.ts b/src/hooks/useMetadataAssets.ts index a658f8c..ad6bd09 100644 --- a/src/hooks/useMetadataAssets.ts +++ b/src/hooks/useMetadataAssets.ts @@ -185,5 +185,7 @@ export const useMetadataAssets = ( foundTmdbId, setBannerImage, bannerSource, + logoLoadError: false, + setLogoLoadError: () => {}, }; }; \ No newline at end of file diff --git a/src/hooks/useUpdatePopup.ts b/src/hooks/useUpdatePopup.ts index cbd9250..6b9fa16 100644 --- a/src/hooks/useUpdatePopup.ts +++ b/src/hooks/useUpdatePopup.ts @@ -74,13 +74,13 @@ export const useUpdatePopup = (): UseUpdatePopupReturn => { // The app will automatically reload with the new version console.log('Update installed successfully'); } else { - toastService.showError('Installation Failed', 'Unable to install the update. Please try again later or check your internet connection.'); + toastService.error('Installation Failed', 'Unable to install the update. Please try again later or check your internet connection.'); // Show popup again after failed installation setShowUpdatePopup(true); } } catch (error) { if (__DEV__) console.error('Error installing update:', error); - toastService.showError('Installation Error', 'An error occurred while installing the update. Please try again later.'); + toastService.error('Installation Error', 'An error occurred while installing the update. Please try again later.'); // Show popup again after error setShowUpdatePopup(true); } finally {