tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From violet...@apache.org
Subject svn commit: r1710779 - /tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMethodMapping.java
Date Tue, 27 Oct 2015 11:19:56 GMT
Author: violetagg
Date: Tue Oct 27 11:19:56 2015
New Revision: 1710779

URL: http://svn.apache.org/viewvc?rev=1710779&view=rev
Log:
Fix https://bz.apache.org/bugzilla/show_bug.cgi?id=58534
Removed repeated conditional test. Patch provided by Anthony Whitford.

Modified:
    tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMethodMapping.java

Modified: tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMethodMapping.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMethodMapping.java?rev=1710779&r1=1710778&r2=1710779&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMethodMapping.java (original)
+++ tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMethodMapping.java Tue Oct 27 11:19:56
2015
@@ -94,7 +94,7 @@ public class PojoMethodMapping {
                         open = method;
                     } else {
                         if (currentClazz == clazzPojo ||
-                                (currentClazz != clazzPojo && !isMethodOverride(open,
method))) {
+                                !isMethodOverride(open, method)) {
                             // Duplicate annotation
                             throw new DeploymentException(sm.getString(
                                     "pojoMethodMapping.duplicateAnnotation",
@@ -107,7 +107,7 @@ public class PojoMethodMapping {
                         close = method;
                     } else {
                         if (currentClazz == clazzPojo ||
-                                (currentClazz != clazzPojo && !isMethodOverride(close,
method))) {
+                                !isMethodOverride(close, method)) {
                             // Duplicate annotation
                             throw new DeploymentException(sm.getString(
                                     "pojoMethodMapping.duplicateAnnotation",
@@ -120,7 +120,7 @@ public class PojoMethodMapping {
                         error = method;
                     } else {
                         if (currentClazz == clazzPojo ||
-                                (currentClazz != clazzPojo && !isMethodOverride(error,
method))) {
+                                !isMethodOverride(error, method)) {
                             // Duplicate annotation
                             throw new DeploymentException(sm.getString(
                                     "pojoMethodMapping.duplicateAnnotation",
@@ -135,8 +135,7 @@ public class PojoMethodMapping {
                         if (messageHandler.targetsSameWebSocketMessageType(otherMessageHandler))
{
                             found = true;
                             if (currentClazz == clazzPojo ||
-                                    (currentClazz != clazzPojo
-                                    && !isMethodOverride(messageHandler.m, otherMessageHandler.m)))
{
+                                !isMethodOverride(messageHandler.m, otherMessageHandler.m))
{
                                 // Duplicate annotation
                                 throw new DeploymentException(sm.getString(
                                         "pojoMethodMapping.duplicateAnnotation",



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message