mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-12-18 06:22:28 +03:00
Fix lock tooltip closure shadowing commit
variable
This commit is contained in:
parent
311a582a8c
commit
a91153aff3
@ -55,7 +55,7 @@
|
||||
<div class="indicators text-base-11">
|
||||
<span class="added">+{added}</span>
|
||||
<span class="removed">-{removed}</span>
|
||||
{#if section.hunk.lockedTo && commits}
|
||||
{#if section.hunk.lockedTo && section.hunk.lockedTo.length > 0 && commits}
|
||||
<div
|
||||
use:tooltip={{
|
||||
text: getLockText(section.hunk.lockedTo, commits),
|
||||
|
@ -9,8 +9,8 @@ export function getLockText(hunkLocks: HunkLock | HunkLock[] | string, commits:
|
||||
const descriptions = locks
|
||||
.filter(unique)
|
||||
.map((lock) => {
|
||||
const commit = commits.find((commit) => {
|
||||
commit.id == lock.commitId;
|
||||
const commit = commits.find((c) => {
|
||||
return c.id == lock.commitId;
|
||||
});
|
||||
const shortCommitId = commit?.id.slice(0, 7);
|
||||
if (commit) {
|
||||
|
Loading…
Reference in New Issue
Block a user