fixed closed editor
Check for editor on close