let PolarBear = Ember.Object.extend({
  schedule(target, f, interval) {
    return Ember.run.later(this, function() {
      f.apply(target);
      this.start(target, f, interval);
    }, interval);
  },

  kill() {
    return Ember.run.cancel(this.get('timer'));
  },

  start(target, f, interval = 500) {
    this.set('timer', this.schedule(target, f, interval));
  }
});

PolarBear.reopenClass({
  type: 'PolarBear'
});

export default PolarBear.create();


let PolarBear = Ember.Object.extend({
  interval: 1000,

  schedule(f) {
    return Ember.run.later(this, function() {
      f.apply(this);
      this.start(f);
    }, this.get('interval'));
  },

  kill() {
    return Ember.run.cancel(this.get('timer'));
  },

  start(f) {
    this.set('timer', this.schedule(f));
  }
});

PolarBear.reopenClass({
  type: 'PolarBear'
});

export default PolarBear;


Revert "Instantiate when it is imporeted"
Revert "Instantiate when it is imporeted"

This reverts commit e80b68bb5791247ae80179e541e04f865002206b.
