SWITCHYARD-1770 - Fix to close editor if file is deleted

Think I finally have this licked.