import formatNumberHelper from 'accounting/helpers/format-number';
import formatMoneyHelper from 'accounting/helpers/format-money';
import Ember from 'ember';

var registerHelper = Ember.HTMLBars.registerHelper;
var makeBoundHelper = Ember.HTMLBars.makeBoundHelper;

export var initialize = function(/* container, app */) {
  registerHelper('format-number', makeBoundHelper(formatNumberHelper));
  registerHelper('format-money', makeBoundHelper(formatMoneyHelper));
};

export default {
  name: 'ember-cli-accounting',

  initialize: initialize
};

import formatNumberHelper from 'accounting/helpers/format-number';
import formatMoneyHelper from 'accounting/helpers/format-money';
import Ember from 'ember';

var registerHelper = Ember.HTMLBars._registerHelper || Ember.HTMLBars.registerHelper;
var makeBoundHelper = Ember.HTMLBars.makeBoundHelper;

export var initialize = function(/* container, app */) {
  registerHelper('format-number', makeBoundHelper(formatNumberHelper));
  registerHelper('format-money', makeBoundHelper(formatMoneyHelper));
};

export default {
  name: 'ember-cli-accounting',

  initialize: initialize
};

Fix `Uncaught TypeError: undefined is not a function`
Fix `Uncaught TypeError: undefined is not a function`

For more information see the following:

https://github.com/cibernox/ember-cli-accounting/issues/7#issuecomment-73835187

https://github.com/emberjs/ember.js/commit/ad62ccfdfd9578884261c96a2af4a6a238bd3ae9
