mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2024-11-22 08:07:56 +01:00
Reset the history if no default history exists on reload
This commit is contained in:
parent
3b8cecbab7
commit
dac6fe0ff4
@ -303,6 +303,9 @@ def load_history(file, name1, name2):
|
||||
def load_default_history(name1, name2):
|
||||
if Path(f'logs/persistent.json').exists():
|
||||
load_history(open(Path(f'logs/persistent.json'), 'rb').read(), name1, name2)
|
||||
else:
|
||||
shared.history['internal'] = []
|
||||
shared.history['visible'] = []
|
||||
|
||||
def load_character(_character, name1, name2):
|
||||
context = ""
|
||||
|
Loading…
Reference in New Issue
Block a user