fix(app): added/deleted file status now correctly calculated
This commit is contained in:
parent
23631a9393
commit
3b93e8d95c
5 changed files with 115 additions and 4 deletions
|
|
@ -500,9 +500,7 @@ export default function Page() {
|
|||
const out = new Map<string, "add" | "del" | "mix">()
|
||||
for (const diff of diffs()) {
|
||||
const file = normalize(diff.file)
|
||||
const add = diff.additions > 0
|
||||
const del = diff.deletions > 0
|
||||
const kind = add && del ? "mix" : add ? "add" : del ? "del" : "mix"
|
||||
const kind = diff.status === "added" ? "add" : diff.status === "deleted" ? "del" : "mix"
|
||||
|
||||
out.set(file, kind)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue