From 04f5a6bcb482ffde9de08805347b78494175b3d6 Mon Sep 17 00:00:00 2001 From: Adam Date: Sun, 26 Dec 2021 12:32:30 -0700 Subject: [PATCH] added throw statements to avoidswallowing errors; addresses #85 (#87) --- Google.Authenticator/TwoFactorAuthenticator.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Google.Authenticator/TwoFactorAuthenticator.cs b/Google.Authenticator/TwoFactorAuthenticator.cs index dfbc8a8..b09e05f 100644 --- a/Google.Authenticator/TwoFactorAuthenticator.cs +++ b/Google.Authenticator/TwoFactorAuthenticator.cs @@ -102,6 +102,10 @@ private static string GenerateQrCodeUrl(int qrPixelsPerModule, string provisionU " https://github.com/codebude/QRCoder/issues/227", e); } + else + { + throw; + } } catch (System.Runtime.InteropServices.ExternalException e) { @@ -112,6 +116,10 @@ private static string GenerateQrCodeUrl(int qrPixelsPerModule, string provisionU " should be set to a value of 10 or less for optimal results.", e); } + else + { + throw; + } } return qrCodeUrl;