mirror of
https://github.com/keymanapp/keyman.git
synced 2026-08-05 00:15:32 +00:00
fix(ios/engine): engine migration must precede installs
This commit is contained in:
parent
a87e3951e5
commit
a1fcaadd85
2 changed files with 14 additions and 0 deletions
|
|
@ -328,6 +328,18 @@ public class ResourceFileManager {
|
|||
throw KMPError.resourceNotInPackage
|
||||
}
|
||||
|
||||
/**
|
||||
* A surprisingly critical line. The Manager.shared instance must be initialized at some
|
||||
* point before the resources are _actually_ stored and reigstered. Otherwise, the initial
|
||||
* Migrations pass (called early in Manager.init) will interpret the installation as from a
|
||||
* different engine version and will break anything installed before it's run.
|
||||
*
|
||||
* Fortunately... all 14.0's installation methods pass through this single method in order to
|
||||
* do the actual "storing" and "registering". So, it's a decent-enough place to force
|
||||
* Manager.shared's init.
|
||||
*/
|
||||
_ = Manager.shared
|
||||
|
||||
do {
|
||||
try copyWithOverwrite(from: package.sourceFolder,
|
||||
to: Storage.active.packageDir(for: package)!)
|
||||
|
|
|
|||
|
|
@ -20,6 +20,8 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
|
|||
KeymanEngine.log.logAppDetails()
|
||||
|
||||
// Replace with your application group id
|
||||
// Ensure this happens before installing any keyboards or models within the engine
|
||||
// whenever using App Group Identifiers.
|
||||
Manager.applicationGroupIdentifier = "group.KMSample"
|
||||
return true
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue