diff --git a/app/src/main/java/eu/faircode/email/ActivitySetup.java b/app/src/main/java/eu/faircode/email/ActivitySetup.java index 57ec798d8c..f08adfd22d 100644 --- a/app/src/main/java/eu/faircode/email/ActivitySetup.java +++ b/app/src/main/java/eu/faircode/email/ActivitySetup.java @@ -479,7 +479,7 @@ public class ActivitySetup extends ActivityBase implements FragmentManager.OnBac new SimpleTask() { @Override protected Long onExecute(Context context, Bundle args) throws IOException, JSONException { - return Log.getDebugInfo(context, R.string.title_debug_info_remark, null, null).id; + return Log.getDebugInfo(context, "setup", R.string.title_debug_info_remark, null, null).id; } @Override diff --git a/app/src/main/java/eu/faircode/email/ActivityView.java b/app/src/main/java/eu/faircode/email/ActivityView.java index 39e5b2e250..22156c68e7 100644 --- a/app/src/main/java/eu/faircode/email/ActivityView.java +++ b/app/src/main/java/eu/faircode/email/ActivityView.java @@ -1481,7 +1481,7 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB sb.append(line).append("\r\n"); } - return Log.getDebugInfo(context, R.string.title_crash_info_remark, null, sb.toString()).id; + return Log.getDebugInfo(context, "crash", R.string.title_crash_info_remark, null, sb.toString()).id; } finally { file.delete(); } @@ -2210,7 +2210,7 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB @Override protected Long onExecute(Context context, Bundle args) throws IOException, JSONException { - return Log.getDebugInfo(context, R.string.title_debug_info_remark, null, null).id; + return Log.getDebugInfo(context, "main", R.string.title_debug_info_remark, null, null).id; } @Override diff --git a/app/src/main/java/eu/faircode/email/Log.java b/app/src/main/java/eu/faircode/email/Log.java index 38dc874c8a..d72e0e8f93 100644 --- a/app/src/main/java/eu/faircode/email/Log.java +++ b/app/src/main/java/eu/faircode/email/Log.java @@ -1780,7 +1780,7 @@ public class Log { } } - static EntityMessage getDebugInfo(Context context, int title, Throwable ex, String log) throws IOException, JSONException { + static EntityMessage getDebugInfo(Context context, String source, int title, Throwable ex, String log) throws IOException, JSONException { StringBuilder sb = new StringBuilder(); sb.append(context.getString(title)).append("\n\n\n\n"); sb.append(getAppInfo(context)); @@ -1813,7 +1813,8 @@ public class Log { draft.thread = draft.msgid; draft.to = new Address[]{myAddress()}; draft.subject = context.getString(R.string.app_name) + " " + - BuildConfig.VERSION_NAME + BuildConfig.REVISION + " debug info"; + BuildConfig.VERSION_NAME + BuildConfig.REVISION + + " debug info - " + source; draft.received = new Date().getTime(); draft.seen = true; draft.ui_seen = true; @@ -1935,7 +1936,7 @@ public class Log { new SimpleTask() { @Override protected Long onExecute(Context context, Bundle args) throws Throwable { - return Log.getDebugInfo(context, R.string.title_unexpected_info_remark, ex, null).id; + return Log.getDebugInfo(context, "report", R.string.title_unexpected_info_remark, ex, null).id; } @Override