mirror of
https://github.com/tapframe/NuvioStreaming.git
synced 2026-04-21 00:32:04 +00:00
metadacrash fix
This commit is contained in:
parent
94e165f0b0
commit
e84a8a58c7
3 changed files with 6 additions and 4 deletions
|
|
@ -96,8 +96,8 @@ export const DropUpMenu = ({ visible, onClose, item, onOptionSelect, isSaved: is
|
||||||
// Robustly determine if the item is in the library (saved)
|
// Robustly determine if the item is in the library (saved)
|
||||||
const isSaved = typeof isSavedProp === 'boolean' ? isSavedProp : !!item.inLibrary;
|
const isSaved = typeof isSavedProp === 'boolean' ? isSavedProp : !!item.inLibrary;
|
||||||
const isWatched = !!isWatchedProp;
|
const isWatched = !!isWatchedProp;
|
||||||
const inTraktWatchlist = isAuthenticated && isInWatchlist(item.id, item.type);
|
const inTraktWatchlist = isAuthenticated && isInWatchlist(item.id, item.type as 'movie' | 'show');
|
||||||
const inTraktCollection = isAuthenticated && isInCollection(item.id, item.type);
|
const inTraktCollection = isAuthenticated && isInCollection(item.id, item.type as 'movie' | 'show');
|
||||||
|
|
||||||
let menuOptions = [
|
let menuOptions = [
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -185,5 +185,7 @@ export const useMetadataAssets = (
|
||||||
foundTmdbId,
|
foundTmdbId,
|
||||||
setBannerImage,
|
setBannerImage,
|
||||||
bannerSource,
|
bannerSource,
|
||||||
|
logoLoadError: false,
|
||||||
|
setLogoLoadError: () => {},
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
@ -74,13 +74,13 @@ export const useUpdatePopup = (): UseUpdatePopupReturn => {
|
||||||
// The app will automatically reload with the new version
|
// The app will automatically reload with the new version
|
||||||
console.log('Update installed successfully');
|
console.log('Update installed successfully');
|
||||||
} else {
|
} 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
|
// Show popup again after failed installation
|
||||||
setShowUpdatePopup(true);
|
setShowUpdatePopup(true);
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (__DEV__) console.error('Error installing update:', 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
|
// Show popup again after error
|
||||||
setShowUpdatePopup(true);
|
setShowUpdatePopup(true);
|
||||||
} finally {
|
} finally {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue