From 6d07a145aa0ec9fb8d1153647138e5c87ea91fe1 Mon Sep 17 00:00:00 2001 From: James Hugman Date: Wed, 25 Oct 2023 18:26:28 +0100 Subject: [PATCH] Bug 1857686 Catch errors when calling reportError --- .../src/main/java/org/mozilla/experiments/nimbus/Nimbus.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/components/nimbus/android/src/main/java/org/mozilla/experiments/nimbus/Nimbus.kt b/components/nimbus/android/src/main/java/org/mozilla/experiments/nimbus/Nimbus.kt index 58fca14764..648ef6d1c5 100644 --- a/components/nimbus/android/src/main/java/org/mozilla/experiments/nimbus/Nimbus.kt +++ b/components/nimbus/android/src/main/java/org/mozilla/experiments/nimbus/Nimbus.kt @@ -410,7 +410,9 @@ open class Nimbus( @AnyThread override fun recordEvent(count: Long, eventId: String) { dbScope.launch { - nimbusClient.recordEvent(eventId, count) + withCatchAll("recordEvent") { + nimbusClient.recordEvent(eventId, count) + } } }