Fixes some issues when opening the editor.