[MM-62395] Don't attempt to set boundaries for a window that is no longer attached (#3278)
Co-authored-by: Mattermost Build <build@mattermost.com>
This commit is contained in:
@@ -66,7 +66,9 @@ export class ModalView<T, T2> {
|
||||
|
||||
// Linux sometimes doesn't have the bound initialized correctly initially, so we wait to set them
|
||||
const setBoundsFunction = () => {
|
||||
this.view.setBounds(getWindowBoundaries(this.windowAttached!));
|
||||
if (this.windowAttached) {
|
||||
this.view.setBounds(getWindowBoundaries(this.windowAttached));
|
||||
}
|
||||
};
|
||||
if (process.platform === 'linux') {
|
||||
setTimeout(setBoundsFunction, 10);
|
||||
|
Reference in New Issue
Block a user