Corrected Core Data save functionality