← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 13216: disable wasted sms detection

 

------------------------------------------------------------
revno: 13216
committer: Long <Long@Long-Laptop>
branch nick: dhis2
timestamp: Fri 2013-12-13 15:26:32 +0700
message:
  disable wasted sms detection
modified:
  dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/sms/DefaultSmsSender.java


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/sms/DefaultSmsSender.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/sms/DefaultSmsSender.java	2013-12-10 08:37:23 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/sms/DefaultSmsSender.java	2013-12-13 08:26:32 +0000
@@ -94,11 +94,12 @@
 
         if ( transportService != null )
         {
-            resultMessage = isWastedSMS( sms );
-            if ( resultMessage == null )
-            {
-                resultMessage = transportService.sendMessage( sms, gatewayId );
-            }
+            // Disable wasted messsage check due to incorrect detection
+            // resultMessage = isWastedSMS( sms );
+            // if ( resultMessage == null )
+
+            resultMessage = transportService.sendMessage( sms, gatewayId );
+
             return resultMessage;
         }
 
@@ -292,20 +293,19 @@
         OutboundSms sms = new OutboundSms();
         sms.setMessage( text );
         sms.setRecipients( recipients );
-        message = isWastedSMS( sms );
-
-        if ( message == null )
-        {
-            try
-            {
-                message = transportService.sendMessage( sms, gateWayId );
-            }
-            catch ( SmsServiceException e )
-            {
-                message = "Unable to send message through sms: " + sms + e.getCause().getMessage();
-
-                log.warn( "Unable to send message through sms: " + sms, e );
-            }
+
+        // Disable wasted messsage check due to incorrect detection
+        // message = isWastedSMS( sms );
+        // if ( message == null )
+
+        try
+        {
+            message = transportService.sendMessage( sms, gateWayId );
+        }
+        catch ( SmsServiceException e )
+        {
+            message = "Unable to send message through sms: " + sms + e.getCause().getMessage();
+            log.warn( "Unable to send message through sms: " + sms, e );
         }
 
         return message;