pub fn write_version(doc: &mut Doc, version: u32) -> Result<(), ModelError>
Record that doc is at version (nothing for the first version, so documents of apps that never changed their storage stay as they are).
doc
version