Fixed removal function

If thebrig is the last extension, then the ext directory should be
removed also.