change object wrapper to conditionally call save or destroy