diff --git a/app/src/debug/java/org/tasks/BuildSetup.java b/app/src/debug/java/org/tasks/BuildSetup.java
index d8a714548..f92487e64 100644
--- a/app/src/debug/java/org/tasks/BuildSetup.java
+++ b/app/src/debug/java/org/tasks/BuildSetup.java
@@ -24,8 +24,10 @@ public class BuildSetup {
public boolean setup() {
Timber.plant(new Timber.DebugTree());
- Timber.plant(new StethoTree());
- Stetho.initializeWithDefaults(context);
+ if (preferences.getBoolean(R.string.p_stetho, false)) {
+ Timber.plant(new StethoTree());
+ Stetho.initializeWithDefaults(context);
+ }
Application application = (Application) context.getApplicationContext();
if (LeakCanary.isInAnalyzerProcess(context)) {
return false;
diff --git a/app/src/debug/res/xml/preferences_debug.xml b/app/src/debug/res/xml/preferences_debug.xml
index c696b1062..4f858f655 100644
--- a/app/src/debug/res/xml/preferences_debug.xml
+++ b/app/src/debug/res/xml/preferences_debug.xml
@@ -5,6 +5,10 @@
android:key="@string/p_leak_canary"
android:title="@string/debug_leak_canary" />
+
+
diff --git a/app/src/main/res/values/keys.xml b/app/src/main/res/values/keys.xml
index 918e55439..2727b0737 100644
--- a/app/src/main/res/values/keys.xml
+++ b/app/src/main/res/values/keys.xml
@@ -283,6 +283,7 @@
Strict mode - Thread
Strict mode - VM
LeakCanary
+ Stetho
Unlock pro
Buy
Debug
@@ -293,6 +294,7 @@
strict_mode_vm
strict_mode_thread
leak_canary
+ p_stetho
debug_pro
warned_play_services
background_sync_unmetered_only