|
|
|
@ -33,14 +33,11 @@ const selectMovieFiles = createSelector(
|
|
|
|
|
|
|
|
|
|
const hasMovieFiles = !!items.length;
|
|
|
|
|
|
|
|
|
|
const sizeOnDisk = items.map((item) => item.size).reduce((prev, curr) => prev + curr, 0);
|
|
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
isMovieFilesFetching: isFetching,
|
|
|
|
|
isMovieFilesPopulated: isPopulated,
|
|
|
|
|
movieFilesError: error,
|
|
|
|
|
hasMovieFiles,
|
|
|
|
|
sizeOnDisk
|
|
|
|
|
hasMovieFiles
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
);
|
|
|
|
@ -104,8 +101,7 @@ function createMapStateToProps() {
|
|
|
|
|
isMovieFilesFetching,
|
|
|
|
|
isMovieFilesPopulated,
|
|
|
|
|
movieFilesError,
|
|
|
|
|
hasMovieFiles,
|
|
|
|
|
sizeOnDisk
|
|
|
|
|
hasMovieFiles
|
|
|
|
|
} = movieFiles;
|
|
|
|
|
|
|
|
|
|
const {
|
|
|
|
@ -161,7 +157,6 @@ function createMapStateToProps() {
|
|
|
|
|
movieCreditsError,
|
|
|
|
|
extraFilesError,
|
|
|
|
|
hasMovieFiles,
|
|
|
|
|
sizeOnDisk,
|
|
|
|
|
previousMovie,
|
|
|
|
|
nextMovie,
|
|
|
|
|
isSmallScreen: dimensions.isSmallScreen,
|
|
|
|
|