From e246c8ee478036f58d9b89060908969dd7ac9cf7 Mon Sep 17 00:00:00 2001 From: rajaa-b Date: Wed, 6 Jul 2022 10:52:37 +0200 Subject: [PATCH] fix(xo-web/tasks): tasks with no bound objects not displayed (#6315) See https://xcp-ng.org/forum/topic/6038/not-seeing-tasks-any-more-as-admin Introduced by dae37c6a5063a40a2ac6df7740b9adbf74c9ac32 --- CHANGELOG.unreleased.md | 2 ++ packages/xo-web/src/common/selectors.js | 9 ++++----- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.unreleased.md b/CHANGELOG.unreleased.md index 0a733b1df..c5f0c2671 100644 --- a/CHANGELOG.unreleased.md +++ b/CHANGELOG.unreleased.md @@ -13,6 +13,8 @@ > Users must be able to say: “I had this issue, happy to know it's fixed” +- [Tasks] Fix tasks not displayed when running CR backup job [Forum#6038](https://xcp-ng.org/forum/topic/6038/not-seeing-tasks-any-more-as-admin) (PR [#6315](https://github.com/vatesfr/xen-orchestra/pull/6315)) + ### Packages to release > When modifying a package, add it here with its release type. diff --git a/packages/xo-web/src/common/selectors.js b/packages/xo-web/src/common/selectors.js index f417dfaa2..730be173a 100644 --- a/packages/xo-web/src/common/selectors.js +++ b/packages/xo-web/src/common/selectors.js @@ -638,11 +638,10 @@ export const getResolvedPendingTasks = create( // { taskId → operation } map instead of { taskRef → operation } map ...defined(linkedObjectsByTaskRefOrId[task.id], []), ] - objects.length > 0 && - resolvedTasks.push({ - ...task, - objects, - }) + resolvedTasks.push({ + ...task, + objects, + }) }) return resolvedTasks }