mirror of
https://github.com/ajnart/homarr.git
synced 2025-11-11 07:55:52 +01:00
Merge pull request #249 from LarveyOfficial/patch-1
🐛 Fix Calendar Item Duplication
This commit is contained in:
@@ -68,7 +68,7 @@ export default function CalendarComponent(props: any) {
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
// Create each Sonarr service and get the medias
|
// Create each Sonarr service and get the medias
|
||||||
const currentSonarrMedias: any[] = [...sonarrMedias];
|
const currentSonarrMedias: any[] = [];
|
||||||
Promise.all(
|
Promise.all(
|
||||||
sonarrServices.map((service) =>
|
sonarrServices.map((service) =>
|
||||||
getMedias(service, 'sonarr').then((res) => {
|
getMedias(service, 'sonarr').then((res) => {
|
||||||
@@ -80,7 +80,7 @@ export default function CalendarComponent(props: any) {
|
|||||||
).then(() => {
|
).then(() => {
|
||||||
setSonarrMedias(currentSonarrMedias);
|
setSonarrMedias(currentSonarrMedias);
|
||||||
});
|
});
|
||||||
const currentRadarrMedias: any[] = [...radarrMedias];
|
const currentRadarrMedias: any[] = [];
|
||||||
Promise.all(
|
Promise.all(
|
||||||
radarrServices.map((service) =>
|
radarrServices.map((service) =>
|
||||||
getMedias(service, 'radarr').then((res) => {
|
getMedias(service, 'radarr').then((res) => {
|
||||||
@@ -92,7 +92,7 @@ export default function CalendarComponent(props: any) {
|
|||||||
).then(() => {
|
).then(() => {
|
||||||
setRadarrMedias(currentRadarrMedias);
|
setRadarrMedias(currentRadarrMedias);
|
||||||
});
|
});
|
||||||
const currentLidarrMedias: any[] = [...lidarrMedias];
|
const currentLidarrMedias: any[] = [];
|
||||||
Promise.all(
|
Promise.all(
|
||||||
lidarrServices.map((service) =>
|
lidarrServices.map((service) =>
|
||||||
getMedias(service, 'lidarr').then((res) => {
|
getMedias(service, 'lidarr').then((res) => {
|
||||||
@@ -104,7 +104,7 @@ export default function CalendarComponent(props: any) {
|
|||||||
).then(() => {
|
).then(() => {
|
||||||
setLidarrMedias(currentLidarrMedias);
|
setLidarrMedias(currentLidarrMedias);
|
||||||
});
|
});
|
||||||
const currentReadarrMedias: any[] = [...readarrMedias];
|
const currentReadarrMedias: any[] = [];
|
||||||
Promise.all(
|
Promise.all(
|
||||||
readarrServices.map((service) =>
|
readarrServices.map((service) =>
|
||||||
getMedias(service, 'readarr').then((res) => {
|
getMedias(service, 'readarr').then((res) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user