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

borinquenkid pushed a commit to branch 9.0.x-h7-improvement-phase3
in repository https://gitbox.apache.org/repos/asf/grails-core.git

commit 659f973ea57edf21840a21a2c00e77a5d0d4ec23
Author: Walter Duque de Estrada <[email protected]>
AuthorDate: Wed Oct 7 18:01:57 2026 -0500

    style: name intentionally empty catch parameters ignored in 
grails-web-common
    
    CodeNarc EmptyCatchBlock only accepts an empty catch block whose parameter 
is
    named ignored. Pure parameter renames, no behaviour change.
    
    Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
---
 .../org/grails/web/errors/GrailsWrappedRuntimeException.groovy      | 6 +++---
 .../src/main/groovy/org/grails/web/json/JSONObject.groovy           | 2 +-
 .../src/main/groovy/org/grails/web/json/JSONTokener.groovy          | 6 +++---
 .../src/main/groovy/org/grails/web/util/WebUtils.groovy             | 2 +-
 4 files changed, 8 insertions(+), 8 deletions(-)

diff --git 
a/grails-web-common/src/main/groovy/org/grails/web/errors/GrailsWrappedRuntimeException.groovy
 
b/grails-web-common/src/main/groovy/org/grails/web/errors/GrailsWrappedRuntimeException.groovy
index 00a39cb882..045c00e0c6 100644
--- 
a/grails-web-common/src/main/groovy/org/grails/web/errors/GrailsWrappedRuntimeException.groovy
+++ 
b/grails-web-common/src/main/groovy/org/grails/web/errors/GrailsWrappedRuntimeException.groovy
@@ -136,7 +136,7 @@ class GrailsWrappedRuntimeException extends GrailsException 
{
                     }
                 }
             }
-            catch (NumberFormatException nfex) {
+            catch (NumberFormatException ignored) {
                 // ignore
             }
         }
@@ -203,7 +203,7 @@ class GrailsWrappedRuntimeException extends GrailsException 
{
                             try {
                                 in = r.getInputStream()
                             }
-                            catch (IOException e1) {
+                            catch (IOException ignored) {
                                 // ignore
                             }
                         }
@@ -243,7 +243,7 @@ class GrailsWrappedRuntimeException extends GrailsException 
{
                 try {
                     reader.close()
                 }
-                catch (IOException e) {
+                catch (IOException ignored) {
                     // ignore
                 }
             }
diff --git 
a/grails-web-common/src/main/groovy/org/grails/web/json/JSONObject.groovy 
b/grails-web-common/src/main/groovy/org/grails/web/json/JSONObject.groovy
index f5efcc7cf3..de795504b3 100644
--- a/grails-web-common/src/main/groovy/org/grails/web/json/JSONObject.groovy
+++ b/grails-web-common/src/main/groovy/org/grails/web/json/JSONObject.groovy
@@ -79,7 +79,7 @@ class JSONObject implements JSONElement, Map {
             javascriptEncoderStateless = (EncodesToWriter) javascriptEncoder
             useStreamingJavascriptEncoder = true
         }
-        catch (Exception e) {
+        catch (Exception ignored) {
             // ignore
         }
     }
diff --git 
a/grails-web-common/src/main/groovy/org/grails/web/json/JSONTokener.groovy 
b/grails-web-common/src/main/groovy/org/grails/web/json/JSONTokener.groovy
index 7283981753..50ad5c4afc 100644
--- a/grails-web-common/src/main/groovy/org/grails/web/json/JSONTokener.groovy
+++ b/grails-web-common/src/main/groovy/org/grails/web/json/JSONTokener.groovy
@@ -343,7 +343,7 @@ class JSONTokener {
                     long time = Long.parseLong(matcher.group(1))
                     return new Date(time)
                 }
-            } catch (Exception e) {
+            } catch (Exception ignored) {
                 // ignored
             }
         }
@@ -362,13 +362,13 @@ class JSONTokener {
                         (s.charAt(1) == 'x' || s.charAt(1) == 'X')) {
                     try {
                         return Integer.parseInt(s.substring(2), 16)
-                    } catch (Exception e) {
+                    } catch (Exception ignored) {
                         /* Ignore the error */
                     }
                 } else {
                     try {
                         return Integer.parseInt(s, 8)
-                    } catch (Exception e) {
+                    } catch (Exception ignored) {
                         /* Ignore the error */
                     }
                 }
diff --git 
a/grails-web-common/src/main/groovy/org/grails/web/util/WebUtils.groovy 
b/grails-web-common/src/main/groovy/org/grails/web/util/WebUtils.groovy
index 7acdf4edd7..7feeb51ba6 100644
--- a/grails-web-common/src/main/groovy/org/grails/web/util/WebUtils.groovy
+++ b/grails-web-common/src/main/groovy/org/grails/web/util/WebUtils.groovy
@@ -325,7 +325,7 @@ class WebUtils extends 
org.springframework.web.util.WebUtils {
                     else {
                         result.put(name, value)
                     }
-                } catch (UnsupportedEncodingException e) {
+                } catch (UnsupportedEncodingException ignored) {
                     // ignore
                 }
             }

Reply via email to