Fix parsing ref id for lightweight tag

This commit is contained in:
Jesse van den Kieboom 2012-07-17 13:56:09 +02:00
parent a46977f572
commit 28c8348da1

View file

@ -130,7 +130,11 @@ namespace GitgHistory
{
Ggit.OId? id = null;
if (head != null && head.parsed_name.rtype == Gitg.RefType.TAG)
if (head != null)
{
id = head.get_id();
if (head.parsed_name.rtype == Gitg.RefType.TAG)
{
// See to resolve to the commit
try
@ -140,9 +144,6 @@ namespace GitgHistory
id = t.get_target_id();
} catch {}
}
else if (head != null)
{
id = head.get_id();
}
if (id == null && application.repository != null)