From 35ebb0bd63ef512afe408baf38f766a0cc800967 Mon Sep 17 00:00:00 2001 From: Martin Haintz Date: Tue, 29 Oct 2024 09:57:00 +0100 Subject: [PATCH] add explanation for setRedactionOptions --- flutter/lib/src/sentry_flutter.dart | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/flutter/lib/src/sentry_flutter.dart b/flutter/lib/src/sentry_flutter.dart index 6f58245b0..79b0856da 100644 --- a/flutter/lib/src/sentry_flutter.dart +++ b/flutter/lib/src/sentry_flutter.dart @@ -245,6 +245,14 @@ mixin SentryFlutter { options.sdk = sdk; } + /// Screen redaction was previously introduced with the SessionReplay feature. + /// Screen redaction is enabled by default for SessionReplay. + /// As we also to use this feature for Screenshot, which previously was not + /// capable of redacting the screenshot, we need to disable redaction for Screenshot by default + /// so we don`t break the existing behavior. + /// As we have only one central place to configure the redaction, + /// we need to set the redaction options to full fill the above default settings. + /// The plan is to unify this behaviour with the next major release. static void _setRedactionOptions(SentryFlutterOptions options) { if (options.experimental.privacy != null) { return;