You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@synapse.apache.org by in...@apache.org on 2009/02/18 09:29:05 UTC

svn commit: r745430 - /synapse/trunk/java/modules/extensions/src/main/java/org/apache/synapse/mediators/throttle/ThrottleMediator.java

Author: indika
Date: Wed Feb 18 08:29:05 2009
New Revision: 745430

URL: http://svn.apache.org/viewvc?rev=745430&view=rev
Log:
minor change

Modified:
    synapse/trunk/java/modules/extensions/src/main/java/org/apache/synapse/mediators/throttle/ThrottleMediator.java

Modified: synapse/trunk/java/modules/extensions/src/main/java/org/apache/synapse/mediators/throttle/ThrottleMediator.java
URL: http://svn.apache.org/viewvc/synapse/trunk/java/modules/extensions/src/main/java/org/apache/synapse/mediators/throttle/ThrottleMediator.java?rev=745430&r1=745429&r2=745430&view=diff
==============================================================================
--- synapse/trunk/java/modules/extensions/src/main/java/org/apache/synapse/mediators/throttle/ThrottleMediator.java (original)
+++ synapse/trunk/java/modules/extensions/src/main/java/org/apache/synapse/mediators/throttle/ThrottleMediator.java Wed Feb 18 08:29:05 2009
@@ -274,11 +274,7 @@
                     handleException("Unable to find onAccept sequence with key : "
                         + onAcceptSeqKey, synCtx);
                 }
-            } else if (onAcceptMediator != null) {
-                return onAcceptMediator.mediate(synCtx);
-            } else {
-                return true;
-            }
+            } else return onAcceptMediator == null || onAcceptMediator.mediate(synCtx);
 
         } else {
             if (onRejectSeqKey != null) {
@@ -289,11 +285,7 @@
                     handleException("Unable to find onReject sequence with key : "
                         + onRejectSeqKey, synCtx);
                 }
-            } else if (onRejectMediator != null) {
-                return onRejectMediator.mediate(synCtx);
-            } else {
-                return false;
-            }
+            } else return onRejectMediator != null && onRejectMediator.mediate(synCtx);
         }
 
         synLog.traceOrDebug("End : Throttle mediator");