Skip to content

Commit

Permalink
Hm...kind of squint and pretend all is fine.
Browse files Browse the repository at this point in the history
  • Loading branch information
radianttap committed Mar 23, 2024
1 parent 6f632da commit 7ce2bfb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ public extension NSManagedObjectModel {
// MARK: - Cached ManagedObjectModels

private let lock = NSLock()
private var map = [ Set<ObjectIdentifier> : NSManagedObjectModel ]()
private let sharedBuilder = SchemaBuilder()
nonisolated(unsafe) private var map = [ Set<ObjectIdentifier> : NSManagedObjectModel ]()
nonisolated(unsafe) private let sharedBuilder = SchemaBuilder()

public extension NSManagedObjectModel {

Expand Down
2 changes: 1 addition & 1 deletion Sources/ManagedModels/SwiftUI/ModelContainer+SwiftUI.swift
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ public extension Scene {
// MARK: - Primitive

// Note: The docs say that a container is only ever created once! So cache it.
private var modelToContainer = [ ObjectIdentifier: NSPersistentContainer ]()
nonisolated(unsafe) private var modelToContainer = [ ObjectIdentifier: NSPersistentContainer ]()

private func makeModelContainer(
for modelTypes : [ any PersistentModel.Type ],
Expand Down

0 comments on commit 7ce2bfb

Please sign in to comment.