From 21a0852d6c010c36c681eafab016ffe122703f2b Mon Sep 17 00:00:00 2001 From: M66B Date: Sat, 13 Mar 2021 21:25:27 +0100 Subject: [PATCH] Reduced logging --- app/src/main/java/eu/faircode/email/ContactInfo.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/ContactInfo.java b/app/src/main/java/eu/faircode/email/ContactInfo.java index 340f74d41c..b59f0f7b06 100644 --- a/app/src/main/java/eu/faircode/email/ContactInfo.java +++ b/app/src/main/java/eu/faircode/email/ContactInfo.java @@ -415,8 +415,11 @@ public class ContactInfo { if (isRecoverable(ex, context)) Log.i(ex); else { - if (!(ex instanceof FileNotFoundException)) - Log.w(ex); + if (ex instanceof FileNotFoundException || + ex instanceof CertPathValidatorException) + Log.i(ex); + else + Log.e(ex); try { file.createNewFile(); } catch (IOException ex1) { @@ -556,7 +559,8 @@ public class ContactInfo { try { return future.get(); } catch (Throwable ex) { - if (ex.getCause() instanceof FileNotFoundException) + if (ex.getCause() instanceof FileNotFoundException || + ex.getCause() instanceof CertPathValidatorException) Log.i(ex); else Log.e(ex);