Author: jleroux
Date: Tue Mar 28 15:26:02 2017 New Revision: 1789163 URL: http://svn.apache.org/viewvc?rev=1789163&view=rev Log: Fixed: Fix Default or Empty Catch block in Java files (OFBIZ-8341) Obviously a PatternSyntaxException should not occur there. So I simply put a comment to document the fact even it it seems obvious. I note though that the repeated pattern is a smell for refactoring... Modified: ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/AbstractModelAction.java ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelFormAction.java ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelTreeAction.java Modified: ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/AbstractModelAction.java URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/AbstractModelAction.java?rev=1789163&r1=1789162&r2=1789163&view=diff ============================================================================== --- ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/AbstractModelAction.java (original) +++ ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/AbstractModelAction.java Tue Mar 28 15:26:02 2017 @@ -715,7 +715,7 @@ public abstract class AbstractModelActio String queryStringEncoded = queryString.replaceAll("&", "%26"); context.put("queryStringEncoded", queryStringEncoded); } catch (PatternSyntaxException e) { - + // obviously a PatternSyntaxException should not occur here } } } else { Modified: ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelFormAction.java URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelFormAction.java?rev=1789163&r1=1789162&r2=1789163&view=diff ============================================================================== --- ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelFormAction.java (original) +++ ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelFormAction.java Tue Mar 28 15:26:02 2017 @@ -218,7 +218,7 @@ public abstract class ModelFormAction { String queryStringEncoded = queryString.replaceAll("&", "%26"); context.put("queryStringEncoded", queryStringEncoded); } catch (PatternSyntaxException e) { - + // obviously a PatternSyntaxException should not occur here } } } else { Modified: ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelTreeAction.java URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelTreeAction.java?rev=1789163&r1=1789162&r2=1789163&view=diff ============================================================================== --- ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelTreeAction.java (original) +++ ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ModelTreeAction.java Tue Mar 28 15:26:02 2017 @@ -417,7 +417,7 @@ public abstract class ModelTreeAction ex String queryStringEncoded = queryString.replaceAll("&", "%26"); context.put("queryStringEncoded", queryStringEncoded); } catch (PatternSyntaxException e) { - + // obviously a PatternSyntaxException should not occur here } } } else { |
Free forum by Nabble | Edit this page |