aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/BaseProtocol.java
diff options
context:
space:
mode:
authorIvan Martinez <ivanfmartinez@users.noreply.github.com>2018-03-25 22:16:09 -0300
committerIvan Martinez <ivanfmartinez@users.noreply.github.com>2018-04-01 18:09:50 -0300
commitbb289a69fa4d292378c5c534e10985be65b2e392 (patch)
tree43ded3eed61aabf70d8212e663aa6c966b55a9dc /src/org/traccar/BaseProtocol.java
parent0117dfeef0a7ffbc7a47d9681811177136336730 (diff)
downloadtrackermap-server-bb289a69fa4d292378c5c534e10985be65b2e392.tar.gz
trackermap-server-bb289a69fa4d292378c5c534e10985be65b2e392.tar.bz2
trackermap-server-bb289a69fa4d292378c5c534e10985be65b2e392.zip
generalization for notifications processing
Diffstat (limited to 'src/org/traccar/BaseProtocol.java')
-rw-r--r--src/org/traccar/BaseProtocol.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/org/traccar/BaseProtocol.java b/src/org/traccar/BaseProtocol.java
index 07adbea5e..7265bd9c1 100644
--- a/src/org/traccar/BaseProtocol.java
+++ b/src/org/traccar/BaseProtocol.java
@@ -92,18 +92,18 @@ public abstract class BaseProtocol implements Protocol {
@Override
public void sendTextCommand(String destAddress, Command command) throws Exception {
- if (Context.getSmppManager() != null) {
+ if (Context.getSmsManager() != null) {
if (command.getType().equals(Command.TYPE_CUSTOM)) {
- Context.getSmppManager().sendMessageSync(destAddress, command.getString(Command.KEY_DATA), true);
+ Context.getSmsManager().sendMessageSync(destAddress, command.getString(Command.KEY_DATA), true);
} else if (supportedTextCommands.contains(command.getType()) && textCommandEncoder != null) {
- Context.getSmppManager().sendMessageSync(destAddress,
+ Context.getSmsManager().sendMessageSync(destAddress,
(String) textCommandEncoder.encodeCommand(command), true);
} else {
throw new RuntimeException(
"Command " + command.getType() + " is not supported in protocol " + getName());
}
} else {
- throw new RuntimeException("SMPP client is not enabled");
+ throw new RuntimeException("SMS is not enabled");
}
}