successfully implemented delete function to work correctly with core data and the array