mirror of
https://github.com/Ellpeck/MLEM.git
synced 2024-11-22 12:58:33 +01:00
fixed a possible crash with empty uis
This commit is contained in:
parent
054dc8c932
commit
b175df7397
1 changed files with 2 additions and 0 deletions
|
@ -166,6 +166,8 @@ namespace MLEM.Ui {
|
|||
}
|
||||
|
||||
public Element GetSelectedElement(RootElement root) {
|
||||
if (root == null)
|
||||
return null;
|
||||
this.selectedElements.TryGetValue(root.Name, out var element);
|
||||
return element;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue