[android-components](../../index.md) / [mozilla.components.feature.downloads](../index.md) / [CoroutineService](index.md) / [onDestroy](./on-destroy.md)

# onDestroy

`@CallSuper open fun onDestroy(): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) [(source)](https://github.com/mozilla-mobile/android-components/blob/master/components/feature/downloads/src/main/java/mozilla/components/feature/downloads/CoroutineService.kt#L58)

Stops all jobs when the service is destroyed.

