Allow text file editing
This commit is contained in:
@ -360,6 +360,12 @@ final class Storage: ObservableObject {
|
||||
return contentScope.readData(at: path)
|
||||
}
|
||||
|
||||
func save(fileContent: String, for fileId: String) -> Bool {
|
||||
guard let contentScope else { return false }
|
||||
let path = filePath(file: fileId)
|
||||
return contentScope.write(fileContent, to: path)
|
||||
}
|
||||
|
||||
// MARK: Settings
|
||||
|
||||
func loadSettings() -> Settings.Data? {
|
||||
|
Reference in New Issue
Block a user