mirror of
https://github.com/atom/atom.git
synced 2026-01-25 14:59:03 -05:00
This regression was caused by a nuance in the way we maintain state in `AtomApplication` for open windows. Specifically, when closing the last window on Windows and Linux, we were explicitly calling `app.quit` *before* removing such window from the list of open ones. In turn, this caused the new `before-quit` behavior introduced in #12619 to work improperly because it made the application wait on saving the state of a stale window before exiting. With this commit we are fixing that by making sure the stale window is removed before calling `app.quit` in `removeWindow`.