"docs/git@developer.sourcefind.cn:OpenDAS/nni.git" did not exist on "36042435ff2eac9291b160637b6bbb38e0c63af5"
Commit 415777ec authored by Brandon Hulston's avatar Brandon Hulston
Browse files

Add error catching for import

parent 27d5eb46
...@@ -133,7 +133,11 @@ ...@@ -133,7 +133,11 @@
let chats = JSON.parse(event.target.result); let chats = JSON.parse(event.target.result);
console.log(chats); console.log(chats);
if (getImportOrigin(chats) == 'gpt') { if (getImportOrigin(chats) == 'gpt') {
chats = convertGptChats(chats); try {
chats = convertGptChats(chats);
} catch (error) {
console.log("Unable to import chats:", error);
}
} }
importChats(chats); importChats(chats);
}; };
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment