docs: function archive() {
              vm.error = undefined;
              var promises = [];
              vm.todos.filter(function (todo) {
                  return todo.completed;
              }).forEach(function (todo) {
                  promises.push(_archive(todo));
              });
  
              $q.all(promises).then(function () {
                  _fetch();
              }).catch(function () {
                  vm.error = 'An error occurred when archiving completed todos';
              });
          }