From 209a48afb0ef5d8da71485a811ad458413e22f4e Mon Sep 17 00:00:00 2001 From: erickgonzalez Date: Fri, 15 Mar 2024 10:50:27 -0600 Subject: [PATCH] #26201 include in 23.01.14 --- .../dotcms/publisher/bundle/business/BundleAPIImpl.java | 9 +++++++-- hotfix_tracking.md | 1 + 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/dotCMS/src/main/java/com/dotcms/publisher/bundle/business/BundleAPIImpl.java b/dotCMS/src/main/java/com/dotcms/publisher/bundle/business/BundleAPIImpl.java index 527db6424aa2..549afc3e95d3 100644 --- a/dotCMS/src/main/java/com/dotcms/publisher/bundle/business/BundleAPIImpl.java +++ b/dotCMS/src/main/java/com/dotcms/publisher/bundle/business/BundleAPIImpl.java @@ -158,8 +158,13 @@ private void internalDeleteBundleAndDependencies (final String bundleId, final U public void deleteBundleAndDependencies(final String bundleId, final User user) throws DotDataException { try { - final PublishAuditStatus bundle = this.publishAuditAPI.getPublishAuditStatus(bundleId); - if (null != bundle) { + final PublishAuditStatus publishAuditStatus = + this.publishAuditAPI.getPublishAuditStatus(bundleId); + Bundle bundle = null; + if (!UtilMethods.isSet(publishAuditStatus)) { + bundle = this.getBundleById(bundleId); + } + if (UtilMethods.isSet(publishAuditStatus) || UtilMethods.isSet(bundle)) { this.internalDeleteBundleAndDependencies(bundleId, user); } else { diff --git a/hotfix_tracking.md b/hotfix_tracking.md index c5307d7a5ff1..71d1d8d8f6f0 100644 --- a/hotfix_tracking.md +++ b/hotfix_tracking.md @@ -216,3 +216,4 @@ This maintenance release includes the following code fixes: 171. https://github.com/dotCMS/core/issues/25653 : Importing Category lists via CSV - import button is disabled #25653 172. https://github.com/dotCMS/core/issues/26815 : Unable to compare history of older versions (Older than latest 20) #26815 173. https://github.com/dotCMS/core/issues/26224 : Need to add the user who create the bundle when you have bundles from other users #26224 +174. https://github.com/dotCMS/core/issues/26201 : Deletion of Unpublished Bundles through API #26201