Fix close tabset when empty behavior

Correctly handle nil when checking the editor for its tabset.