Revert #9, go back to generating sequential ids on save (fixes #10)