From 75a6bf30416ed7569301d36e2b738b21cfc79511 Mon Sep 17 00:00:00 2001 From: Shubham Goyal Date: Tue, 10 Dec 2024 15:14:41 +0530 Subject: [PATCH] report non fatals to firebase --- app/src/org/commcare/logging/AndroidLogger.java | 5 +++++ app/src/org/commcare/logging/PreInitLogger.java | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/app/src/org/commcare/logging/AndroidLogger.java b/app/src/org/commcare/logging/AndroidLogger.java index 338648d52c..2b1d4ede21 100755 --- a/app/src/org/commcare/logging/AndroidLogger.java +++ b/app/src/org/commcare/logging/AndroidLogger.java @@ -82,4 +82,9 @@ public int logSize() { public void halt() { //Meh. } + + @Override + public void logException(Throwable e) { + CrashUtil.reportException(e); + } } diff --git a/app/src/org/commcare/logging/PreInitLogger.java b/app/src/org/commcare/logging/PreInitLogger.java index 40e485a525..2670f06354 100755 --- a/app/src/org/commcare/logging/PreInitLogger.java +++ b/app/src/org/commcare/logging/PreInitLogger.java @@ -1,6 +1,7 @@ package org.commcare.logging; import org.commcare.android.javarosa.AndroidLogEntry; +import org.commcare.utils.CrashUtil; import org.javarosa.core.api.ILogger; import org.javarosa.core.log.IFullLogSerializer; import org.javarosa.core.log.StreamLogSerializer; @@ -72,4 +73,9 @@ public int logSize() { public void halt() { // TODO Auto-generated method stub } + + @Override + public void logException(Throwable e) { + CrashUtil.reportException(e); + } }