fixed problem when editor stopped working after image insert