# Computed model change

**URL:** <https://discuss.emberjs.com/t/computed-model-change/11179>\
**Category:** Learning Team\
**Created:** [July 17, 2016, 7:14am UTC](https://discuss.emberjs.com/t/computed-model-change/11179 "2016-07-17T07:14:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rashe](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/rashe/32/12396_2.png) [@Rashe](https://discuss.emberjs.com/u/Rashe)\
**Post date:** [July 17, 2016, 7:14am UTC](https://discuss.emberjs.com/t/computed-model-change/11179/1 "2016-07-17T07:14:48Z")

</div>

I have a computed

```
compare: Ember.computed("model", function() {
    return this.get('somevalue').getData(this.get('model'));
  })

```

And service

```
 getData(content) {
    let store = this.get('store'),
      promise = getStoreData(store, 'comparetimeframe', this.getParams(content)),
     self = this;
    promise.then(function(data){
      promise.data = {
        sameTimePercent: data.get('change'),
        pieCompareData : {
          pieData: [{y: 103}, {y: 103}]
        }
      };
    }, function (fail) {
      return fail;
    });
    return promise;
  },

```

As I understand now the “compare” listens to model change. But I make changes in some array in the model. How to trigger that model has been changed?

---

<div class="post-metadata">

**Author:** ![Bauke](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/bauke/32/12190_2.png) [@Bauke](https://discuss.emberjs.com/u/Bauke)\
**Post date:** [July 18, 2016, 7:11am UTC](https://discuss.emberjs.com/t/computed-model-change/11179/2 "2016-07-18T07:11:19Z")

</div>

You should tell the computed property to specifically listen to any changes to that array.

```auto
compare: Ember.computed("model.myArray.[]", function() {
  ...
});

```
