Skip to content

Commit 7b7fd9e

Browse files
lblodergetsentry-bot
authored andcommitted
Fix warning about profile converter in Android (#4931)
Co-authored-by: Sentry Github Bot <[email protected]>
1 parent 4e047a8 commit 7b7fd9e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

sentry/src/main/java/io/sentry/util/InitUtil.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,12 +108,14 @@ public static IProfileConverter initializeProfileConverter(@NotNull SentryOption
108108
}
109109

110110
private static boolean shouldInitializeProfiler(@NotNull SentryOptions options) {
111-
return options.isContinuousProfilingEnabled()
111+
return Platform.isJvm()
112+
&& options.isContinuousProfilingEnabled()
112113
&& options.getContinuousProfiler() instanceof NoOpContinuousProfiler;
113114
}
114115

115116
private static boolean shouldInitializeProfileConverter(@NotNull SentryOptions options) {
116-
return options.isContinuousProfilingEnabled()
117+
return Platform.isJvm()
118+
&& options.isContinuousProfilingEnabled()
117119
&& options.getProfilerConverter() instanceof NoOpProfileConverter;
118120
}
119121

0 commit comments

Comments
 (0)