# probable onValueChanged leak with ux:Property

**URL:** <https://forums.fusetools.com/t/probable-onvaluechanged-leak-with-ux-property/3813>\
**Category:** Bug Reports\
**Created:** [July 19, 2016, 4:15pm UTC](https://forums.fusetools.com/t/probable-onvaluechanged-leak-with-ux-property/3813 "2016-07-19T16:15:04Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Uldis](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/uldis/32/657_2.png) [@Uldis](https://forums.fusetools.com/u/Uldis)\
**Post date:** [July 19, 2016, 4:15pm UTC](https://forums.fusetools.com/t/probable-onvaluechanged-leak-with-ux-property/3813/1 "2016-07-19T16:15:04Z")

</div>

Hey, following a short chat with @duckers, tried to reproduce what seems to me like a probable leak when using ux:Property. It may very well be a display of bad practice on my part, but worth a shot anyway.

Repro: [https://dl.dropboxusercontent.com/u/11750787/ovc-test.zip](https://dl.dropboxusercontent.com/u/11750787/ovc-test.zip)

Launched local preview on OSX + pre-release Fuse 0.22.0.6993.

Step to reproduce:

1. Click “Switch page” five times

2. Make a change to `SomeItem.js` file (add a newline somewhere) and save it

3. Watch Monitor spit out the following:

What seems weird is that the `this.Label.onValueChanged()` from `SomeItem.js` seems to be firing several times in a row, with different values.

---

<div class="post-metadata">

**Author:** ![Anders\_Lassen](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/anders_lassen/32/522_2.png) [@Anders\_Lassen](https://forums.fusetools.com/u/Anders_Lassen)\
**Post date:** [July 21, 2016, 12:08pm UTC](https://forums.fusetools.com/t/probable-onvaluechanged-leak-with-ux-property/3813/2 "2016-07-21T12:08:04Z")

</div>

Hi,

We’ve done a lot of cleanup around this. Keep an eye on the changelog in upcoming releases.

Ideally, we recommend using reactive operators instead of `onValueChanged`. If you need to do async operations, you can do this:

```auto
var foo = someObservable.map(function(x) {

    var res = Observable();

    somethingAsync().then(function(result) {
        res.value = result;
    });

    return res;

}).inner();

```
