This is an automated email from the ASF dual-hosted git repository.

mridulpathak pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
     new 079fe0aefb Fixed: updateBlogEntry checks the wrong field for existing 
article text (OFBIZ-13545)
079fe0aefb is described below

commit 079fe0aefb96e219de10133eec2ea2d046f40027
Author: Mridul Pathak <[email protected]>
AuthorDate: Tue Sep 8 10:41:46 2026 +0530

    Fixed: updateBlogEntry checks the wrong field for existing article text 
(OFBIZ-13545)
    
    updateBlogEntry checked blog.articleText, a field getBlogEntry never 
populates on its result map (only a same-named local variable existed in 
minilang's shared-scope version, lost in the conversion to an isolated service 
call), instead of the correctly-populated blog.articleData. Since 
blog.articleText was always null, every edit to an existing blog post's article 
text created a duplicate "ARTICLE" sub-content instead of updating the original 
one's text in place, matching the parallel [...]
---
 .../src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy        | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/applications/content/src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy
 
b/applications/content/src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy
index 31aec8f702..2df1e63612 100644
--- 
a/applications/content/src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy
+++ 
b/applications/content/src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy
@@ -168,7 +168,7 @@ Map updateBlogEntry() {
         }
     }
 
-    if (!blog.articleText && parameters.articleData) {
+    if (!blog.articleData && parameters.articleData) {
         run service: 'createTextContent',
                 with: [
                         dataResourceTypeId: 'ELECTRONIC_TEXT',

Reply via email to