Author: jleroux
Date: Mon Dec 18 08:26:33 2017 New Revision: 1818530 URL: http://svn.apache.org/viewvc?rev=1818530&view=rev Log: Improved: Always check if debug verbose is on when using Debug.logVerbose() (OFBIZ-10052) This completes the work done so far by removing double check in cases not using brackets, like if (Debug.verboseOn()) if (Debug.verboseOn()) Debug.logVerbose() Forgot to commit those one in plugins :/ Modified: ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/EbayHelper.java ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/ProductsExportToEbay.java ofbiz/ofbiz-plugins/trunk/ebaystore/src/main/java/org/apache/ofbiz/ebaystore/EbayStore.java ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/ProductUtil.java ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/SolrProductSearch.java Modified: ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/EbayHelper.java URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/EbayHelper.java?rev=1818530&r1=1818529&r2=1818530&view=diff ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/EbayHelper.java (original) +++ ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/EbayHelper.java Mon Dec 18 08:26:33 2017 @@ -105,7 +105,7 @@ public class EbayHelper { public static Map<String, Object> postItem(String postItemsUrl, StringBuffer generatedXmlData, String devID, String appID, String certID, String callName, String compatibilityLevel, String siteID) throws IOException { if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Request of " + callName + " To eBay:\n" + generatedXmlData.toString(), module); + Debug.logVerbose("Request of " + callName + " To eBay:\n" + generatedXmlData.toString(), module); } HttpURLConnection connection = (HttpURLConnection) (new URL(postItemsUrl)).openConnection(); connection.setDoInput(true); @@ -137,7 +137,7 @@ public class EbayHelper { result = ServiceUtil.returnFailure(EbayHelper.toString(inputStream)); } if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Response of " + callName + " From eBay:\n" + response, module); + Debug.logVerbose("Response of " + callName + " From eBay:\n" + response, module); } return result; } Modified: ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/ProductsExportToEbay.java URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/ProductsExportToEbay.java?rev=1818530&r1=1818529&r2=1818530&view=diff ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/ProductsExportToEbay.java (original) +++ ofbiz/ofbiz-plugins/trunk/ebay/src/main/java/org/apache/ofbiz/ebay/ProductsExportToEbay.java Mon Dec 18 08:26:33 2017 @@ -133,7 +133,7 @@ public class ProductsExportToEbay { private static Map<String, Object> postItem(String postItemsUrl, StringBuffer dataItems, String devID, String appID, String certID, String callName, String compatibilityLevel, String siteID) throws IOException { if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Request of " + callName + " To eBay:\n" + dataItems.toString(), module); + Debug.logVerbose("Request of " + callName + " To eBay:\n" + dataItems.toString(), module); } HttpURLConnection connection = (HttpURLConnection)(new URL(postItemsUrl)).openConnection(); connection.setDoInput(true); @@ -167,7 +167,7 @@ public class ProductsExportToEbay { } if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Response of " + callName + " From eBay:\n" + response, module); + Debug.logVerbose("Response of " + callName + " From eBay:\n" + response, module); } return result; Modified: ofbiz/ofbiz-plugins/trunk/ebaystore/src/main/java/org/apache/ofbiz/ebaystore/EbayStore.java URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ebaystore/src/main/java/org/apache/ofbiz/ebaystore/EbayStore.java?rev=1818530&r1=1818529&r2=1818530&view=diff ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ebaystore/src/main/java/org/apache/ofbiz/ebaystore/EbayStore.java (original) +++ ofbiz/ofbiz-plugins/trunk/ebaystore/src/main/java/org/apache/ofbiz/ebaystore/EbayStore.java Mon Dec 18 08:26:33 2017 @@ -165,7 +165,7 @@ public class EbayStore { private static Map<String, Object> postItem(String postItemsUrl, StringBuffer dataItems, String devID, String appID, String certID, String callName, String compatibilityLevel, String siteID) throws IOException { if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Request of " + callName + " To eBay:\n" + dataItems.toString(), module); + Debug.logVerbose("Request of " + callName + " To eBay:\n" + dataItems.toString(), module); } HttpURLConnection connection = (HttpURLConnection)(new URL(postItemsUrl)).openConnection(); connection.setDoInput(true); @@ -199,7 +199,7 @@ public class EbayStore { } if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Response of " + callName + " From eBay:\n" + response, module); + Debug.logVerbose("Response of " + callName + " From eBay:\n" + response, module); } return result; Modified: ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/ProductUtil.java URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/ProductUtil.java?rev=1818530&r1=1818529&r2=1818530&view=diff ============================================================================== --- ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/ProductUtil.java (original) +++ ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/ProductUtil.java Mon Dec 18 08:26:33 2017 @@ -56,7 +56,7 @@ public final class ProductUtil { Locale locale = new Locale("de_DE"); if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Solr: Getting product content for productId '" + productId + "'", module); + Debug.logVerbose("Solr: Getting product content for productId '" + productId + "'", module); } try { Modified: ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/SolrProductSearch.java URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/SolrProductSearch.java?rev=1818530&r1=1818529&r2=1818530&view=diff ============================================================================== --- ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/SolrProductSearch.java (original) +++ ofbiz/ofbiz-plugins/trunk/solr/src/main/java/org/apache/ofbiz/solr/SolrProductSearch.java Mon Dec 18 08:26:33 2017 @@ -139,7 +139,7 @@ public abstract class SolrProductSearch Collection<SolrInputDocument> docs = new ArrayList<SolrInputDocument>(); if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Solr: Indexing document: " + doc1.toString(), module); + Debug.logVerbose("Solr: Indexing document: " + doc1.toString(), module); } docs.add(doc1); @@ -215,7 +215,7 @@ public abstract class SolrProductSearch for (Iterator<Map<String, Object>> fieldListIterator = fieldList.iterator(); fieldListIterator.hasNext();) { SolrInputDocument doc1 = SolrUtil.generateSolrDocument(fieldListIterator.next()); if (Debug.verboseOn()) { - if (Debug.verboseOn()) Debug.logVerbose("Solr: Indexing document: " + doc1.toString(), module); + Debug.logVerbose("Solr: Indexing document: " + doc1.toString(), module); } docs.add(doc1); } |
Free forum by Nabble | Edit this page |