bug: set_doc was changed after save