1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2024-10-29 23:12:39 +01:00

Fixed: Bulk series deletion for unmonitored series

Closes #6933
This commit is contained in:
Bogdan 2024-07-06 02:34:56 +03:00 committed by GitHub
parent a779a5fad2
commit 81ac73299a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -88,8 +88,7 @@ function DeleteSeriesModalContent(props: DeleteSeriesModalContentProps) {
const { totalEpisodeFileCount, totalSizeOnDisk } = useMemo(() => {
return series.reduce(
(acc, s) => {
const { statistics = { episodeFileCount: 0, sizeOnDisk: 0 } } = s;
(acc, { statistics = {} }) => {
const { episodeFileCount = 0, sizeOnDisk = 0 } = statistics;
acc.totalEpisodeFileCount += episodeFileCount;
@ -155,17 +154,17 @@ function DeleteSeriesModalContent(props: DeleteSeriesModalContentProps) {
</div>
<ul>
{series.map((s) => {
const { episodeFileCount = 0, sizeOnDisk = 0 } = s.statistics;
{series.map(({ title, path, statistics = {} }) => {
const { episodeFileCount = 0, sizeOnDisk = 0 } = statistics;
return (
<li key={s.title}>
<span>{s.title}</span>
<li key={title}>
<span>{title}</span>
{deleteFiles && (
<span>
<span className={styles.pathContainer}>
-<span className={styles.path}>{s.path}</span>
-<span className={styles.path}>{path}</span>
</span>
{!!episodeFileCount && (