migration system
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import json
|
||||
from pathlib import Path
|
||||
|
||||
from untitled import PACKAGE_ROOT, model
|
||||
from untitled import PACKAGE_ROOT, migration, model
|
||||
|
||||
SAVE_FOLDER = PACKAGE_ROOT / "saves"
|
||||
|
||||
@@ -26,7 +26,7 @@ def load(name, folder=None):
|
||||
|
||||
with open(save_file) as f:
|
||||
data = json.load(f)
|
||||
|
||||
data = migration.migrate(data)
|
||||
save = model.Save.from_dict(data)
|
||||
|
||||
return save
|
||||
|
||||
Reference in New Issue
Block a user