refactor: Migrate file-based data storage to database
This commit is contained in:
@@ -129,11 +129,8 @@ def load_json(path):
|
||||
return json.load(open(path, 'r')) if os.path.exists(path) else None
|
||||
|
||||
def create_default_personas():
|
||||
# Persona data is now stored in the Persona DB table; ensure the directory exists for sample files.
|
||||
if not os.path.exists(config.PERSONAS_DIR): os.makedirs(config.PERSONAS_DIR)
|
||||
if not os.path.exists(config.PERSONAS_FILE):
|
||||
try:
|
||||
with open(config.PERSONAS_FILE, 'w') as f: json.dump({}, f, indent=2)
|
||||
except: pass
|
||||
|
||||
def get_length_presets():
|
||||
presets = {}
|
||||
|
||||
Reference in New Issue
Block a user