This check `file.fullPath === EditorManager.getCurrentlyViewedPath()` will never be true since you already checked `!file` in line 877. Seems like you need to combine this if with the one on line 877.