fix(label): paginate label lookup in +update to avoid clobbering fields #363
Loading…
Reference in New Issue
No description provided.
Delete Branch "heke1228/gitlink-cli:fix/label-update-pagination"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
背景
label +update的fetchLabel只GET标签列表的第一页(其注释却称“分页匹配 id”)。当目标标签不在第一页时返回未命中,runUpdate回退到空description与默认色#1E90FF,随后的PATCH覆盖服务端真实值——静默数据丢失。改动
fetchLabel真正分页,直到命中或列表耗尽。PATCH。description/color被保留。验证
go build ./...、go test ./shortcuts/label/通过。