Added default NTP server

This commit is contained in:
ChronosX88 2019-05-23 00:01:09 +04:00
parent 0264e87296
commit e68d41ffb7

View File

@ -23,6 +23,7 @@ import io.github.chronosx88.influence.XMPPConnection;
public class AppHelper extends MultiDexApplication {
private static Application instance;
public final static String APP_NAME = "Influence";
public final static String DEFAULT_NTP_SERVER = "0.europe.pool.ntp.org";
private static String jid;
private static RoomHelper chatDB;
@ -84,7 +85,7 @@ public class AppHelper extends MultiDexApplication {
boolean isTrueTimeIsOn = false;
while(!isTrueTimeIsOn) {
try {
TrueTime.build().initialize();
TrueTime.build().withNtpHost(DEFAULT_NTP_SERVER).initialize();
isTrueTimeIsOn = true;
} catch (IOException e) {
e.printStackTrace();