added update and commit functionality for items