From 26fec907fd3d51deb2d94b4f7d17fd40e4bf9fed Mon Sep 17 00:00:00 2001 From: Jeonhui Date: Tue, 23 May 2023 14:37:55 +0900 Subject: [PATCH] feat: saveContext func update to public --- CoreDataStorage.podspec | 2 +- Sources/CoreDataStorage/Classes/CoreDataStroage.swift | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/CoreDataStorage.podspec b/CoreDataStorage.podspec index 0e6bd54..c6f9ec3 100644 --- a/CoreDataStorage.podspec +++ b/CoreDataStorage.podspec @@ -8,7 +8,7 @@ Pod::Spec.new do |s| s.name = 'CoreDataStorage' - s.version = '1.0.0' + s.version = '1.0.1' s.summary = 'CoreData with Combine' # This description is used to generate tags and improve search results. diff --git a/Sources/CoreDataStorage/Classes/CoreDataStroage.swift b/Sources/CoreDataStorage/Classes/CoreDataStroage.swift index 35359d0..9feec25 100644 --- a/Sources/CoreDataStorage/Classes/CoreDataStroage.swift +++ b/Sources/CoreDataStorage/Classes/CoreDataStroage.swift @@ -39,8 +39,10 @@ public final class CoreDataStorage { } return container }() - - // manual Save Context +} + +public extension CoreDataStorage { + /// manual Save Context func saveContext() { let context = persistentContainer.viewContext if context.hasChanges { @@ -51,9 +53,7 @@ public final class CoreDataStorage { } } } -} - -public extension CoreDataStorage { + /// Create /// - Parameter value: Struct: Entitable /// - Returns: created Entity into Struct