Implemented check for optimistic concurrency in updates and deletes.