gilPts commented on code in PR #517:
URL: https://github.com/apache/ofbiz-framework/pull/517#discussion_r1147826282


##########
applications/product/groovyScripts/product/promo/ProductPromoActionServices.groovy:
##########
@@ -161,9 +169,11 @@ def productGWP() {
                 }
                 optionProductIds.remove(alternateGwpProductId)
                 productId = alternateGwpProductId
-                product = from("Product").where("productId", 
productId).cache().queryOne()
+                product = from('Product').where('productId', 
productId).cache().queryOne()
             } else {
-                logWarning(UtilProperties.getMessage(resource_error, 
"OrderAnAlternateGwpProductIdWasInPlaceButWasEitherNotValidOrIsNoLongerInStockForId",
 UtilMisc.toMap("alternateGwpProductId", alternateGwpProductId), 
cart.getLocale()))
+                logWarning(UtilProperties.getMessage(resource_error,
+                        
'OrderAnAlternateGwpProductIdWasInPlaceButWasEitherNotValidOrIsNoLongerInStockForId',
+                        [alternateGwpProductId: alternateGwpProductId], 
cart.getLocale()))

Review Comment:
   There is no need of quotes in map key, see 
https://groovy-lang.org/syntax.html#_maps
   The only case is when the key has some specifics :
   
   >  You can also pass quoted strings as well as keys: ["name": "Guillaume"]. 
This is mandatory if your key string isn’t a valid identifier, for example if 
you wanted to create a string key containing a dash like in: ["street-name": 
"Main street"]. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@ofbiz.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to