Skip to content

Commit d3dce33

Browse files
committed
enhance: disable OPEN DETAILS button when one of submodule revision is lost
Signed-off-by: leo <longshuang@msn.cn>
1 parent 87768e9 commit d3dce33

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Models/DiffResult.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -612,7 +612,9 @@ public class SubmoduleDiff
612612
public RevisionSubmodule Old { get; set; } = null;
613613
public RevisionSubmodule New { get; set; } = null;
614614

615-
public bool CanOpenDetails => File.Exists(Path.Combine(FullPath, ".git")) && Old != null && New != null;
615+
public bool CanOpenDetails => File.Exists(Path.Combine(FullPath, ".git")) &&
616+
Old != null && Old.Commit.Author != User.Invalid &&
617+
New != null && New.Commit.Author != User.Invalid;
616618
}
617619

618620
public class DiffResult

0 commit comments

Comments
 (0)