Fixed bug: Window open wasn't being called after being terminated