Fix exception when pressing Add Controllers button

This commit is contained in:
spacechase0 2019-05-17 18:28:25 -04:00
parent 8c2dcff723
commit 759cd66f18

View file

@ -29,8 +29,13 @@ namespace BetterJoyForCemu {
private bool ContainsText(ListBox a, String manu) { private bool ContainsText(ListBox a, String manu) {
foreach (var v in a.Items) foreach (var v in a.Items)
if ((v as dynamic).Text.Equals(manu)) {
dynamic d = v as dynamic;
if (d.Text == null)
continue;
if (d.Text.Equals(manu))
return true; return true;
}
return false; return false;
} }