@steveck-chung,
I have done the changes as per your suggestion.

Below is the code which we have changed. Please let us know whether is this ok to continue
append: function(item) {
      var self = this;
      var lastItem;
      if (!Array.isArray(item)) {
        self.insertItem(item);
        lastItem = item;
      } else {
        item.forEach(function(value) {
          self.insertItem(value);
        });
		lastItem = item[item.length - 1];
      }
      onContentChanged(lastItem);
      return this;
    },