Add button to remove a tag
This commit is contained in:
@ -151,9 +151,7 @@ final class Storage: ObservableObject {
|
||||
Completely delete a post file from the content folder
|
||||
*/
|
||||
func delete(page pageId: String) -> Bool {
|
||||
guard let contentScope else {
|
||||
return false
|
||||
}
|
||||
guard let contentScope else { return false }
|
||||
guard contentScope.deleteFile(at: pageMetadataPath(page: pageId)) else {
|
||||
return false
|
||||
}
|
||||
@ -213,9 +211,7 @@ final class Storage: ObservableObject {
|
||||
Completely delete a post file from the content folder
|
||||
*/
|
||||
func delete(post postId: String) -> Bool {
|
||||
guard let contentScope else {
|
||||
return false
|
||||
}
|
||||
guard let contentScope else { return false }
|
||||
return contentScope.deleteFile(at: postFilePath(post: postId))
|
||||
}
|
||||
|
||||
@ -258,6 +254,11 @@ final class Storage: ObservableObject {
|
||||
return contentScope.move(tagFilePath(tag: tagId), to: tagFilePath(tag: newId))
|
||||
}
|
||||
|
||||
func delete(tag tagId: String) -> Bool {
|
||||
guard let contentScope else { return false }
|
||||
return contentScope.deleteFile(at: tagFilePath(tag: tagId))
|
||||
}
|
||||
|
||||
// MARK: Files
|
||||
|
||||
func size(of file: String) -> Int? {
|
||||
|
Reference in New Issue
Block a user