anchor.diff:        return store.retrieveObject(treeEntry.sha, "Tree").then((GitObject tree) {
           return Future.forEach((tree as TreeObject).entries, (TreeEntry entry) {
             return _removeEntryRecursively(store, newDir, entry);
  -          }).then((_) {
  -          // There might be untracked files in the project.Only delete the
  +        }).then((_) {
  +          // There might be untracked files in the project. Only delete the
             // directory if it is empty.
             return FileOps.listFiles(newDir).then((entries) {
  -            if (entries.length == 0) {
  +            if (entries.isEmpty) {
                 return newDir.remove();
               }
             });
  
positive.code:           TreeEntry oldEntry = mergeEntry['old'];
            TreeEntry newEntry = mergeEntry['new'];
            if (newEntry.isBlob) {
              return ObjectUtils.expandBlob(dir, store, newEntry.name, newEntry.sha);
            }
            return store.retrieveObjectList([oldEntry.sha, newEntry.sha],
                "Tree").then((trees) {
              return smartCheckout(dir, store, trees[0], trees[1]);
            });
          });
        });
      });
  
negative.code:   }
  
    static Future smartCheckout(chrome.DirectoryEntry dir, ObjectStore store,
        TreeObject oldTree, TreeObject newTree) {
      TreeDiffResult diff = Merge.diffTree(oldTree, newTree);
      return Future.forEach(diff.adds, (TreeEntry entry) {
        if (entry.isBlob) {
  