# onDispose not called (ParticleSystem)

**URL:** <https://forum.babylonjs.com/t/ondispose-not-called-particlesystem/26269>\
**Category:** Bugs\
**Tags:** particles\
**Created:** [December 24, 2021, 5:10am UTC](https://forum.babylonjs.com/t/ondispose-not-called-particlesystem/26269 "2021-12-24T05:10:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nawar](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/nawar/32/14923_2.png) [@Nawar](https://forum.babylonjs.com/u/Nawar)\
**Post date:** [December 24, 2021, 5:10am UTC](https://forum.babylonjs.com/t/ondispose-not-called-particlesystem/26269/1 "2021-12-24T05:10:51Z")

</div>

Hello!

> **[Babylon.js Playground](https://playground.babylonjs.com/#77BKY4%23145)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL 3D scenes

My code starting at line 54. The observer is called, but the callback is not

---

<div class="post-metadata">

**Author:** ![Evgeni\_Popov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/evgeni_popov/32/4432_2.png) [@Evgeni\_Popov](https://forum.babylonjs.com/u/Evgeni_Popov)\
**Post date:** [December 24, 2021, 10:02am UTC](https://forum.babylonjs.com/t/ondispose-not-called-particlesystem/26269/2 "2021-12-24T10:02:27Z")

</div>

The `onDispose` callback does not exist on the GPU particle system. You must use the observable for this one (note that `onDispose` is somewhat deprecated, internally it is using the observable).
