aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java
diff options
context:
space:
mode:
authorsteckbrief <steckbrief@chefmail.de>2015-10-05 16:05:56 +0200
committersteckbrief <steckbrief@chefmail.de>2015-10-05 16:05:56 +0200
commit383d1aa9e64a245f17dd7ec6d177bb286a489f62 (patch)
tree0b9d8a50cab4384063669b794ce91804b0a7545c /src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java
parentc3c42e415ddd7832fea66766377fb4f0d935537a (diff)
parent1db6e6d5eadbad04768be823b8dbd32827b9b5c3 (diff)
Merge remote-tracking branch 'remotes/origin/trz/rename' into trz/rebase
Manually merged conflicting files: src/main/AndroidManifest.xml src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java src/main/java/eu/siacs/conversations/generator/IqGenerator.java src/main/java/eu/siacs/conversations/ui/AboutPreference.java
Diffstat (limited to 'src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java')
-rw-r--r--src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java17
1 files changed, 2 insertions, 15 deletions
diff --git a/src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java b/src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java
index 3607b69a..190e42bc 100644
--- a/src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java
+++ b/src/main/java/eu/siacs/conversations/generator/AbstractGenerator.java
@@ -12,9 +12,9 @@ import java.util.List;
import java.util.Locale;
import java.util.TimeZone;
+import de.thedevstack.conversationsplus.ConversationsPlusApplication;
import de.tzur.conversations.Settings;
import eu.siacs.conversations.services.XmppConnectionService;
-import eu.siacs.conversations.utils.PhoneHelper;
public abstract class AbstractGenerator {
private final String[] FEATURES = {
@@ -35,8 +35,6 @@ public abstract class AbstractGenerator {
"urn:xmpp:receipts"
};
private String mVersion = null;
- //FIXME use appname or similar!!!!!!!!!!!11elf
- public final String IDENTITY_NAME = "Conversations+";
public final String IDENTITY_TYPE = "phone";
private static final SimpleDateFormat DATE_FORMAT = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss'Z'", Locale.US);
@@ -47,20 +45,9 @@ public abstract class AbstractGenerator {
this.mXmppConnectionService = service;
}
- protected String getIdentityVersion() {
- if (mVersion == null) {
- this.mVersion = PhoneHelper.getVersionName(mXmppConnectionService);
- }
- return this.mVersion;
- }
-
- protected String getIdentityName() {
- return IDENTITY_NAME + " " + getIdentityVersion();
- }
-
public String getCapHash() {
StringBuilder s = new StringBuilder();
- s.append("client/" + IDENTITY_TYPE + "//" + getIdentityName() + "<");
+ s.append("client/" + IDENTITY_TYPE + "//" + ConversationsPlusApplication.getNameAndVersion() + "<");
MessageDigest md;
try {
md = MessageDigest.getInstance("SHA-1");