1
0
mirror of https://github.com/mastodon/mastodon-ios.git synced 2024-12-13 09:07:16 +01:00
mastodon-app-ufficiale-ipho.../MastodonSDK/Sources/MastodonCore/Persistence/FileManager+Shared.swift
Nathan Mattes 45028373d4 Store accounts in container (IOS-192)
In case you see an empty app: Add your account again.

Background: As we need access to the account from the extensions and the extensions can't access the documents-directory but the group-container, well, the accounts will live there from now on.
2024-01-02 23:05:25 +01:00

19 lines
457 B
Swift

// Copyright © 2023 Mastodon gGmbH. All rights reserved.
import Foundation
import MastodonCommon
public extension FileManager {
var documentsDirectory: URL? {
urls(for: .documentDirectory, in: .userDomainMask).first
}
var cachesDirectory: URL? {
urls(for: .cachesDirectory, in: .userDomainMask).first
}
var sharedDirectory: URL? {
containerURL(forSecurityApplicationGroupIdentifier: AppName.groupID)
}
}