Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ed4b4ac3 authored by Young-Ho Cha's avatar Young-Ho Cha Committed by Steve Kondik
Browse files

check ntpserver as empty string instead of null



mServer cannot set null, because string from resource always returns
non-null charsequence

Change-Id: I8d6a6fdbc34267ee361e7bd20719887268161870
Signed-off-by: default avatarYoung-Ho Cha <ganadist@gmail.com>
parent 80a8ccc3
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -24,6 +24,7 @@ import android.net.NetworkInfo;
import android.net.SntpClient;
import android.os.SystemClock;
import android.provider.Settings;
import android.text.TextUtils;

/**
 * {@link TrustedTime} that connects with a remote NTP server as its trusted
@@ -79,7 +80,7 @@ public class NtpTrustedTime implements TrustedTime {

    @Override
    public boolean forceRefresh() {
        if (mServer == null) {
        if (TextUtils.isEmpty(mServer)) {
            // missing server, so no trusted time available
            return false;
        }