update codemirror editor