+2
-2
appview/state/pull.go
+2
-2
appview/state/pull.go
···
629
630
result, err := us.Branches(f.OwnerDid(), f.RepoName)
631
if err != nil {
632
-
log.Println("failed to reach knotserver", err)
633
return
634
}
635
···
1143
return
1144
}
1145
1146
-
branches := result.Branches
1147
sort.Slice(branches, func(i int, j int) bool {
1148
return branches[i].Commit.Committer.When.After(branches[j].Commit.Committer.When)
1149
})
···
629
630
result, err := us.Branches(f.OwnerDid(), f.RepoName)
631
if err != nil {
632
+
log.Println("failed to fetch branches", err)
633
return
634
}
635
···
1143
return
1144
}
1145
1146
+
branches := result.Branches
1147
sort.Slice(branches, func(i int, j int) bool {
1148
return branches[i].Commit.Committer.When.After(branches[j].Commit.Committer.When)
1149
})
+2
-2
appview/state/repo.go
+2
-2
appview/state/repo.go
···
185
return nil, err
186
}
187
188
-
if !slices.ContainsFunc(result.Branches, func(branch types.Branch) bool {
189
return branch.Name == f.Ref
190
}) {
191
forkInfo.Status = types.MissingBranch
···
556
return
557
}
558
559
-
slices.SortFunc(result.Branches, func(a, b types.Branch) int {
560
if a.IsDefault {
561
return -1
562
}
···
185
return nil, err
186
}
187
188
+
if !slices.ContainsFunc(result.Branches, func(branch types.Branch) bool {
189
return branch.Name == f.Ref
190
}) {
191
forkInfo.Status = types.MissingBranch
···
556
return
557
}
558
559
+
slices.SortFunc(result.Branches, func(a, b types.Branch) int {
560
if a.IsDefault {
561
return -1
562
}