Skip to content

Commit

Permalink
update CmlLibWinFormSample
Browse files Browse the repository at this point in the history
fix null version in ChangeLogs
  • Loading branch information
AlphaBs committed Jun 2, 2021
1 parent 0463b7c commit fe8aae0
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions CmlLibWinFormSample/ChangeLog.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,12 @@ private async void ChangeLog_Load(object sender, EventArgs e)

private async void btnLoad_Click(object sender, EventArgs e)
{
btnLoad.Enabled = false;
var version = listBox1.SelectedItem?.ToString();
if (string.IsNullOrEmpty(version))
return;

var version = listBox1.SelectedItem.ToString();
btnLoad.Enabled = false;

var body = await changelogs.GetChangelogHtml(version);
webBrowser1.DocumentText = body;

Expand Down

0 comments on commit fe8aae0

Please sign in to comment.