Merged changes to allow items to be deleted