Skip to content
Prev Previous commit
Next Next commit
Removes 1 minute check since this is already implemented
  • Loading branch information
antonis committed Oct 4, 2024
commit 00e48fb841be02283152ceb5df32586d5c0809f3
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@
import java.util.Properties;
import java.util.Set;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;

import io.sentry.Breadcrumb;
import io.sentry.DateUtils;
Expand Down Expand Up @@ -381,10 +380,8 @@ public void fetchNativeRelease(Promise promise) {
}

public void fetchNativeAppStart(Promise promise) {
AppStartMetrics appStartMetrics = AppStartMetrics.getInstance();
if (!appStartMetrics.isAppLaunchedInForeground() ||
appStartMetrics.getAppStartTimeSpan().getDurationMs() > TimeUnit.MINUTES.toMillis(1)) {
logger.log(SentryLevel.WARNING, "Invalid app start data: app not launched in foreground or app start took too long (>60s)");
if (!AppStartMetrics.getInstance().isAppLaunchedInForeground()) {
logger.log(SentryLevel.WARNING, "Invalid app start data: app not launched in foreground.");
promise.resolve(null);
}

Expand Down