aboutsummaryrefslogtreecommitdiff
path: root/packages/client/src/views/RepositoryTree.vue
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2021-06-11 20:06:59 +0200
committerHampusM <hampus@hampusmat.com>2021-06-11 20:06:59 +0200
commit34bc24151ba2ca46b2b08d9cef8e3c6c866d1c0a (patch)
tree11f5812e5088c3b80f4983a9d6f5f913c75754f9 /packages/client/src/views/RepositoryTree.vue
parent5b72b479ba3acf391a61a2c04ca694e30d108565 (diff)
Fixed BaseBreadcrumb, RepositoryTree & the log and tree views
Diffstat (limited to 'packages/client/src/views/RepositoryTree.vue')
-rw-r--r--packages/client/src/views/RepositoryTree.vue11
1 files changed, 5 insertions, 6 deletions
diff --git a/packages/client/src/views/RepositoryTree.vue b/packages/client/src/views/RepositoryTree.vue
index b14c4e4..351591a 100644
--- a/packages/client/src/views/RepositoryTree.vue
+++ b/packages/client/src/views/RepositoryTree.vue
@@ -71,14 +71,13 @@ export default {
if(tree_data) {
if(tree_data.type === "tree") {
- let tree_trees = Object.entries(tree_data.tree).filter((entry) => entry[1].type === "tree");
- tree_trees = tree_trees.sort((a, b) => a[0].localeCompare(b[0]));
+ let tree_trees = tree_data.tree.filter((entry) => entry.type === "tree");
+ tree_trees = tree_trees.sort((a, b) => a.name.localeCompare(b.name));
- let tree_blobs = Object.entries(tree_data.tree).filter((entry) => entry[1].type === "blob");
- tree_blobs = tree_blobs.sort((a, b) => a[0].localeCompare(b[0]));
+ let tree_blobs = tree_data.tree.filter((entry) => entry.type === "blob");
+ tree_blobs = tree_blobs.sort((a, b) => a.name.localeCompare(b.name));
- tree.value = Object.fromEntries(tree_trees.concat(tree_blobs));
- console.log(tree.value);
+ tree.value = tree_trees.concat(tree_blobs);
} else {
blob_content.value = tree_data.content;
}