Skip to content

Commit

Permalink
Fix empty "latest" column in GUI.
Browse files Browse the repository at this point in the history
Closes KSP-CKAN#1296.

Yes, my "tidying" of the code in KSP-CKAN#1295 changed the logic. Ooops!

Thanks to @plague006 for spotting this. :)
  • Loading branch information
pjf committed Jul 16, 2015
1 parent bf0e4cf commit e44f884
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions GUI/GUIMod.cs
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,6 @@ public GUIMod(Module mod, IRegistryQuerier registry, KSPVersion current_ksp_vers
Version latest_version = null;
var ksp_version = mod.ksp_version;

InstalledVersion = installed_version != null ? installed_version.ToString() : "-";
LatestVersion = latest_version != null ? latest_version.ToString() : "-";

try
{
var latest_available = registry.LatestAvailable(mod.identifier, current_ksp_version);
Expand All @@ -72,6 +69,9 @@ public GUIMod(Module mod, IRegistryQuerier registry, KSPVersion current_ksp_vers
latest_version = installed_version;
}

InstalledVersion = installed_version != null ? installed_version.ToString() : "-";
LatestVersion = latest_version != null ? latest_version.ToString() : "-";

// Let's try to find the compatibility for this mod. If it's not in the registry at
// all (because it's a DarkKAN mod) then this might fail.

Expand Down

0 comments on commit e44f884

Please sign in to comment.