File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
sentry/src/main/java/io/sentry Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -272,13 +272,6 @@ private static synchronized void init(
272272 "You are running Android. Please, use SentryAndroid.init. "
273273 + options .getClass ().getName ());
274274 }
275- if (isEnabled ()) {
276- options
277- .getLogger ()
278- .log (
279- SentryLevel .WARNING ,
280- "Sentry has been already initialized. Previous configuration will be overwritten." );
281- }
282275
283276 if (!preInitConfigurations (options )) {
284277 return ;
@@ -288,6 +281,13 @@ private static synchronized void init(
288281 Sentry .globalHubMode = globalHubMode ;
289282 final boolean shouldInit = InitUtil .shouldInit (globalScope .getOptions (), options , isEnabled ());
290283 if (shouldInit ) {
284+ if (isEnabled ()) {
285+ options
286+ .getLogger ()
287+ .log (
288+ SentryLevel .WARNING ,
289+ "Sentry has been already initialized. Previous configuration will be overwritten." );
290+ }
291291 globalScope .replaceOptions (options );
292292
293293 final IScopes scopes = getCurrentScopes ();
You can’t perform that action at this time.
0 commit comments