Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,7 @@ open class DuckDuckGoApplication : HasAndroidInjector, Application(), LifecycleO
scheduleOfflinePixels()

notificationRegistrar.registerApp()
registerReceiver(shortcutReceiver, IntentFilter(ShortcutBuilder.USE_OUR_APP_SHORTCUT_ADDED_ACTION))

initializeHttpsUpgrader()
submitUnsentFirePixels()
Expand Down Expand Up @@ -299,7 +300,6 @@ open class DuckDuckGoApplication : HasAndroidInjector, Application(), LifecycleO
Timber.i("Suppressing app launch pixel")
return
}
registerReceiver(shortcutReceiver, IntentFilter(ShortcutBuilder.USE_OUR_APP_SHORTCUT_ADDED_ACTION))
pixel.fire(APP_LAUNCH)
}

Expand All @@ -312,11 +312,6 @@ open class DuckDuckGoApplication : HasAndroidInjector, Application(), LifecycleO
}
}

@OnLifecycleEvent(Lifecycle.Event.ON_STOP)
fun onAppStopped() {
unregisterReceiver(shortcutReceiver)
}

companion object {
private const val APP_RESTART_CAUSED_BY_FIRE_GRACE_PERIOD: Long = 10_000L
}
Expand Down