You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
var commit = yield repo.loadAs("commit", commitHash);
var tree = yield repo.loadAs("tree", commit.tree);
But when I tried this, the commit was an array with the first element being an object containing tree, while the second element was just undefined.
I end up using the destructuring syntax let [commit] = ... to get around this, but what is the second element for? Even when I pass in a garbage commit hash, it's undefined (at first I thought it might be a [val, err] pattern).