I am facing similar issue th the same error. @jabakobob have you resolve this and how? Many thanks
Post
Replies
Boosts
Views
Activity
Tap, you'd need to make a fresh new Subscription ( replicate ) , then the section to add that one will appear under the Add Binary form. Only the ones that are not in review or not approved but in "Waiting Review" will appear there. And Submit them from the App as one bundle. Do not submit Subscription separately.
I’m referring to the injection of a model container into the environment. We accomplish this by declaring the type as follows:
.modelContainer(for: [Book.self, Author.self])
For instance:
struct Example: App {
@State private var appData = ApplicationData.shared
var body: some Scene {
WindowGroup {
ContentView()
.environment(appData)
.modelContainer(for: [Book.self, Author.self])
}
}
}
I was wondering if we could implement a feature similar to the navigationPath() type-erasing functionality. This allows us to define a heterogeneous set of types, as we can do with:
@State private var path = NavigationPath()
Instead of explicitly declaring:
@State private var path = [Book] ()
Is there a way to build ( if not already a way) into Swift Language a similar capability for environment injection, enabling the injection of a heterogeneous set of types without needing to declare the type explicitly?
Apparently it also deletes automatically as per this :
for index in indexSet {
let animalToDelete = animals[index]
if navigationContext.selectedAnimal?.persistentModelID == animalToDelete.persistentModelID {
navigationContext.selectedAnimal = nil
}
modelContext.delete(animalToDelete)
}
}
The sample above uses the SwiftData autosave feature, which is enabled by default when creating a ModelContainerusing the modelContainer(for:inMemory:isAutosaveEnabled:isUndoEnabled:onSetup:) modifier. If this feature is disabled, the removeAnimals method needs to explicitly save the change by calling the ModelContext method save(); for example:
do {
for index in indexSet {
let animalToDelete = animals[index]
if navigationContext.selectedAnimal?.persistentModelID == animalToDelete.persistentModelID {
navigationContext.selectedAnimal = nil
}
modelContext.delete(animalToDelete)
}
try modelContext.save()
} catch {
// Handle error.
}
}
https://developer.apple.com/documentation/swiftdata/deleting-persistent-data-from-your-app
My App is approved and in App Store. I have never changed anything on Subscriptions. Perhaps I shall have and a blank or a dot and resubmit ? Now subscription wasn't approved - rejected due to localisation. Message says :
We have returned your in-app purchase products to you as the required binary was not submitted. When you are ready to submit the binary, please resubmit the in-app purchase products with the binary.
Starting :
https://developer.apple.com/app-store/pathway/
https://developer.apple.com/storekit/
https://developer.apple.com/design/human-interface-guidelines/in-app-purchase/