Skip to content

Commit 982610d

Browse files
use class from string to fix dynamically linked frameworks
1 parent b081bd5 commit 982610d

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

ios/RNSentry.mm

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,6 @@
77
#import "RCTConvert.h"
88
#endif
99

10-
#import <React/RCTTextView.h>
11-
#import <React/RCTImageView.h>
12-
1310
#if __has_include(<hermes/hermes.h>) && SENTRY_PROFILING_SUPPORTED
1411
#define SENTRY_PROFILING_ENABLED 1
1512
#import <Sentry/SentryProfilingConditionals.h>
@@ -674,10 +671,10 @@ - (void) addReplayRNRedactClasses: (NSDictionary *_Nullable)replayOptions
674671
{
675672
NSMutableArray *_Nonnull classesToRedact = [[NSMutableArray alloc] init];
676673
if ([replayOptions[@"maskAllImages"] boolValue] == YES) {
677-
[classesToRedact addObject: [RCTImageView class]];
674+
[classesToRedact addObject: NSClassFromString(@"RCTImageView")];
678675
}
679676
if ([replayOptions[@"maskAllText"] boolValue] == YES) {
680-
[classesToRedact addObject: [RCTTextView class]];
677+
[classesToRedact addObject: NSClassFromString(@"RCTTextView")];
681678
}
682679
[PrivateSentrySDKOnly addReplayRedactClasses: classesToRedact];
683680
}

0 commit comments

Comments
 (0)