Updated editor example to preserve filename