Use Constants.DEBUG instead of BuildConfig.DEBUG to allow debugging of release builds
This commit is contained in:
parent
3ea7eb3b2b
commit
6541cc57b5
|
@ -178,7 +178,7 @@ public class KeychainApplication extends Application {
|
|||
|
||||
private void updateLoggingStatus() {
|
||||
Timber.uprootAll();
|
||||
boolean enableDebugLogging = BuildConfig.DEBUG;
|
||||
boolean enableDebugLogging = Constants.DEBUG;
|
||||
if (enableDebugLogging) {
|
||||
Timber.plant(new DebugTree());
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ import android.support.annotation.Nullable;
|
|||
|
||||
import com.google.auto.value.AutoValue;
|
||||
import org.bouncycastle.util.encoders.Hex;
|
||||
import org.sufficientlysecure.keychain.BuildConfig;
|
||||
import org.sufficientlysecure.keychain.Constants;
|
||||
import org.sufficientlysecure.keychain.ui.util.KeyFormattingUtils;
|
||||
|
||||
|
||||
|
@ -76,7 +76,7 @@ public abstract class SecurityTokenInfo implements Parcelable {
|
|||
}
|
||||
|
||||
public static SecurityTokenInfo newInstanceDebugKeyserver() {
|
||||
if (!BuildConfig.DEBUG) {
|
||||
if (!Constants.DEBUG) {
|
||||
throw new UnsupportedOperationException("This operation is only available in debug builds!");
|
||||
}
|
||||
return SecurityTokenInfo.create(TransportType.NFC, TokenType.UNKNOWN,
|
||||
|
@ -85,7 +85,7 @@ public abstract class SecurityTokenInfo implements Parcelable {
|
|||
}
|
||||
|
||||
public static SecurityTokenInfo newInstanceDebugUri() {
|
||||
if (!BuildConfig.DEBUG) {
|
||||
if (!Constants.DEBUG) {
|
||||
throw new UnsupportedOperationException("This operation is only available in debug builds!");
|
||||
}
|
||||
return SecurityTokenInfo.create(TransportType.NFC, TokenType.UNKNOWN,
|
||||
|
@ -94,7 +94,7 @@ public abstract class SecurityTokenInfo implements Parcelable {
|
|||
}
|
||||
|
||||
public static SecurityTokenInfo newInstanceDebugLocked() {
|
||||
if (!BuildConfig.DEBUG) {
|
||||
if (!Constants.DEBUG) {
|
||||
throw new UnsupportedOperationException("This operation is only available in debug builds!");
|
||||
}
|
||||
return SecurityTokenInfo.create(TransportType.NFC, TokenType.UNKNOWN,
|
||||
|
@ -103,7 +103,7 @@ public abstract class SecurityTokenInfo implements Parcelable {
|
|||
}
|
||||
|
||||
public static SecurityTokenInfo newInstanceDebugLockedHard() {
|
||||
if (!BuildConfig.DEBUG) {
|
||||
if (!Constants.DEBUG) {
|
||||
throw new UnsupportedOperationException("This operation is only available in debug builds!");
|
||||
}
|
||||
return SecurityTokenInfo.create(TransportType.NFC, TokenType.UNKNOWN,
|
||||
|
|
|
@ -33,7 +33,7 @@ import android.view.View.OnClickListener;
|
|||
import android.view.ViewGroup;
|
||||
import android.view.animation.Animation;
|
||||
|
||||
import org.sufficientlysecure.keychain.BuildConfig;
|
||||
import org.sufficientlysecure.keychain.Constants;
|
||||
import org.sufficientlysecure.keychain.R;
|
||||
import org.sufficientlysecure.keychain.securitytoken.SecurityTokenInfo;
|
||||
import org.sufficientlysecure.keychain.ui.CreateKeyActivity.FragAction;
|
||||
|
@ -57,7 +57,7 @@ public class CreateSecurityTokenWaitFragment extends Fragment {
|
|||
((BaseSecurityTokenActivity) this.getActivity()).checkDeviceConnection();
|
||||
}
|
||||
|
||||
setHasOptionsMenu(BuildConfig.DEBUG);
|
||||
setHasOptionsMenu(Constants.DEBUG);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in a new issue