diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/CommonServices.java b/framework/common/src/main/java/org/apache/ofbiz/common/CommonServices.java index 94e38e45bc..5e56dc72f9 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/CommonServices.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/CommonServices.java @@ -275,14 +275,6 @@ public class CommonServices { return ServiceUtil.returnError(UtilProperties.getMessage(resource, "CommonEntityTestFailure", locale)); } - /* - try { - newEntity.remove(); - } catch (GenericEntityException e) { - Debug.logError(e, module); - } - */ - return ServiceUtil.returnSuccess(); } diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/FindServices.java b/framework/common/src/main/java/org/apache/ofbiz/common/FindServices.java index 38d9b9a7b4..c5d1a98745 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/FindServices.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/FindServices.java @@ -112,7 +112,6 @@ public class FindServices { // Contained in the associated entity. // Those extra fields will be ignored in the second half of this method. Map>> normalizedFields = new LinkedHashMap>>(); - //StringBuffer queryStringBuf = new StringBuffer(); for (String fieldNameRaw: inputFields.keySet()) { // The name as it appeas in the HTML form String fieldNameRoot = null; // The entity field name. Everything to the left of the first "_" if // it exists, or the whole word, if not. @@ -130,7 +129,6 @@ public class FindServices { continue; } - //queryStringBuffer.append(fieldNameRaw + "=" + fieldValue); queryStringMap.put(fieldNameRaw, fieldValue); iPos = fieldNameRaw.indexOf("_"); // Look for suffix diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/JsLanguageFileMappingCreator.java b/framework/common/src/main/java/org/apache/ofbiz/common/JsLanguageFileMappingCreator.java index afd1f38a77..f413d1d80b 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/JsLanguageFileMappingCreator.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/JsLanguageFileMappingCreator.java @@ -62,7 +62,6 @@ public class JsLanguageFileMappingCreator { String jsFilePostFix = ".js"; String dateJsLocalePrefix = "date-"; String validateLocalePrefix = "messages_"; - //String validateMethLocalePrefix = "methods__"; String jqueryUiLocalePrefix = "jquery.ui.datepicker-"; String dateTimePickerPrefix = "jquery-ui-timepicker-"; String defaultLocaleDateJs = "en-US"; diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/KeywordSearchUtil.java b/framework/common/src/main/java/org/apache/ofbiz/common/KeywordSearchUtil.java index da439f6749..dec9e01ac6 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/KeywordSearchUtil.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/KeywordSearchUtil.java @@ -59,7 +59,6 @@ public final class KeywordSearchUtil { private KeywordSearchUtil () {} public static String getSeparators() { - // String separators = ";: ,.!?\t\"\'\r\n\\/()[]{}*%<>-+_"; String seps = UtilProperties.getPropertyValue("keywordsearch", "index.keyword.separators", ";: ,.!?\t\"\'\r\n\\/()[]{}*%<>-+_"); return seps; } @@ -157,9 +156,7 @@ public final class KeywordSearchUtil { // replace all %% with % int dblPercIdx = -1; while ((dblPercIdx = strSb.indexOf("%%")) >= 0) { - //Debug.logInfo("before strSb: " + strSb, module); strSb.replace(dblPercIdx, dblPercIdx+2, "%"); - //Debug.logInfo("after strSb: " + strSb, module); } token = strSb.toString(); } diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/email/EmailServices.java b/framework/common/src/main/java/org/apache/ofbiz/common/email/EmailServices.java index 09f73fb3ee..d1dd4ae67c 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/email/EmailServices.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/email/EmailServices.java @@ -525,17 +525,6 @@ public class EmailServices { screenContextAtt.putAll(bodyParameters); screensAtt.render(xslfoAttachScreenLocation); - /* - try { // save generated fo file for debugging - String buf = writer.toString(); - java.io.FileWriter fw = new java.io.FileWriter(new java.io.File("/tmp/file1.xml")); - fw.write(buf.toString()); - fw.close(); - } catch (IOException e) { - Debug.logError(e, "Couldn't save xsl-fo xml debug file: " + e.toString(), module); - } - */ - // create the input stream for the generation StreamSource src = new StreamSource(new StringReader(writer.toString())); diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/geo/GeoWorker.java b/framework/common/src/main/java/org/apache/ofbiz/common/geo/GeoWorker.java index 47330aa9d2..46e3d04d6a 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/geo/GeoWorker.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/geo/GeoWorker.java @@ -59,8 +59,6 @@ public final class GeoWorker { return UtilMisc.toList(geo); } - //Debug.logInfo("Expanding geo : " + geo, module); - List geoList = new LinkedList(); List thisGeoAssoc = null; try { @@ -78,12 +76,7 @@ public final class GeoWorker { } geoList.addAll(expandGeoGroup(nextGeo)); } - } else { - //Debug.logInfo("No associated geos with this group", module); - } - - //Debug.logInfo("Expanded to : " + geoList, module); - + } return geoList; } @@ -125,7 +118,6 @@ public final class GeoWorker { if (geoList == null || geo == null) { return false; } - //Debug.logInfo("Contains Geo : " + geoList.contains(geo)); return geoList.contains(geo); } diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/login/LoginServices.java b/framework/common/src/main/java/org/apache/ofbiz/common/login/LoginServices.java index 4c72cec54f..2e8c47551a 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/login/LoginServices.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/login/LoginServices.java @@ -242,8 +242,6 @@ public class LoginServices { result.put("userLogin", userLogin); result.put(ModelService.RESPONSE_MESSAGE, ModelService.RESPOND_SUCCESS); } else { - //Debug.logInfo("Entered password [" + encodedPassword + "], Entered password OldFunnyHexEncode [" + encodedPasswordOldFunnyHexEncode + "], db password [" + userLogin.getString("currentPassword") + "]", module); - // password is incorrect, but this may be the result of a stale cache entry, // so lets clear the cache and try again if this is the first pass // but only if authFatalError is not true; this would mean the single authenticator failed @@ -327,7 +325,6 @@ public class LoginServices { ulhCreateMap.put("passwordUsed", password); } - //Debug.logInfo(new Exception(), "=================== Creating new UserLoginHistory at " + UtilDateTime.nowTimestamp(), module); delegator.create("UserLoginHistory", ulhCreateMap); } } @@ -712,7 +709,6 @@ public class LoginServices { } } - //result.put(ModelService.RESPONSE_MESSAGE, ModelService.RESPOND_SUCCESS); result.put("updatedUserLogin", userLoginToUpdate); return result; } @@ -730,8 +726,6 @@ public class LoginServices { List errorMessageList = new LinkedList(); Locale locale = (Locale) context.get("locale"); - //boolean useEncryption = "true".equals(UtilProperties.getPropertyValue("security", "password.encrypt")); - String userLoginId = (String) context.get("userLoginId"); String errMsg = null; @@ -746,13 +740,6 @@ public class LoginServices { // security: don't create a user login if the specified partyId (if not empty) already exists // unless the logged in user has permission to do so (same partyId or PARTYMGR_CREATE) if (UtilValidate.isNotEmpty(partyId)) { - //GenericValue party = null; - //try { - // party = EntityQuery.use(delegator).from("Party").where("partyId", partyId).queryOne(); - //} catch (GenericEntityException e) { - // Debug.logWarning(e, "", module); - //} - if (!loggedInUserLogin.isEmpty()) { // security check: userLogin partyId must equal partyId, or must have PARTYMGR_CREATE permission if (!partyId.equals(loggedInUserLogin.getString("partyId"))) { diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/preferences/PreferenceServices.java b/framework/common/src/main/java/org/apache/ofbiz/common/preferences/PreferenceServices.java index 9bc7a88fb0..9ac178dad7 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/preferences/PreferenceServices.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/preferences/PreferenceServices.java @@ -201,7 +201,6 @@ public class PreferenceServices { String userLoginId = PreferenceWorker.getUserLoginId(context, false); String userPrefTypeId = (String) context.get("userPrefTypeId"); - //Debug.logError("In removeUserPreference userLoginId=" + userLoginId + ", userPrefTypeId=" + userPrefTypeId, module); if (UtilValidate.isEmpty(userLoginId) || UtilValidate.isEmpty(userPrefTypeId)) { return ServiceUtil.returnError(UtilProperties.getMessage(resource, "setPreference.invalidArgument", locale)); } diff --git a/framework/common/src/main/java/org/apache/ofbiz/common/qrcode/QRCodeServices.java b/framework/common/src/main/java/org/apache/ofbiz/common/qrcode/QRCodeServices.java index 521d3c27fc..f961c98b3b 100644 --- a/framework/common/src/main/java/org/apache/ofbiz/common/qrcode/QRCodeServices.java +++ b/framework/common/src/main/java/org/apache/ofbiz/common/qrcode/QRCodeServices.java @@ -181,7 +181,6 @@ public class QRCodeServices { } if (UtilValidate.isNotEmpty(verifyOutput) && verifyOutput.booleanValue()) { - // Debug.logInfo("Original Message:[" + message + "]", module); Decoder decoder = new Decoder(); Map decodeHints = new EnumMap<>(DecodeHintType.class); decodeHints.put(DecodeHintType.TRY_HARDER, Boolean.TRUE); @@ -202,11 +201,9 @@ public class QRCodeServices { } catch (NotFoundException e) { // do nothing } - // Debug.logInfo("Text in QR Code with logo:[" + result.getText() + "]", module); if (UtilValidate.isNotEmpty(result) && !result.getText().equals(message)) { detectorResult = new Detector(bitMatrix).detect(decodeHints); result = decoder.decode(detectorResult.getBits(), decodeHints); - // Debug.logInfo("Text in QR Code without logo:[" + result.getText() + "]", module); if (!result.getText().equals(message)) { return ServiceUtil.returnError(UtilProperties.getMessage("QRCodeUiLabels", "GeneratedTextNotMatchOriginal", new Object[]{result.getText(), message}, locale)); } @@ -216,7 +213,6 @@ public class QRCodeServices { } else { detectorResult = new Detector(bitMatrix).detect(decodeHints); DecoderResult result = decoder.decode(detectorResult.getBits(), decodeHints); - // Debug.logInfo("Text in QR Code:[" + result.getText() + "]", module); if (!result.getText().equals(message)) { return ServiceUtil.returnError(UtilProperties.getMessage("QRCodeUiLabels", "GeneratedTextNotMatchOriginal", new Object[]{result.getText(), message}, locale)); }