replmd: Only modify the object if it actually changed