beta12 for porting old format

This commit is contained in:
marlon-erler
2026-09-26 16:02:41 +02:00
parent eaf40d8e37
commit 5a647da2de
7 changed files with 11 additions and 6 deletions
+3 -1
View File
@@ -1751,11 +1751,12 @@
}; };
// load // load
this.loadInfo = () => { this.loadInfo = () => {
const info = this.storageModel.readStringifiable( let info = this.storageModel.readStringifiable(
this.getInfoPath(), this.getInfoPath(),
ChatInfoReference ChatInfoReference
); );
this.info = info || _ChatModel.generateChatInfo("0", "0", "standard" /* Standard */); this.info = info || _ChatModel.generateChatInfo("0", "0", "standard" /* Standard */);
this.storeInfo();
}; };
this.handleInfo = (info) => { this.handleInfo = (info) => {
this.info = info; this.info = info;
@@ -1958,6 +1959,7 @@
this.handleFileContent(fileContent); this.handleFileContent(fileContent);
}; };
this.handleFileContent = (fileContent) => { this.handleFileContent = (fileContent) => {
console.log(fileContent.type);
if (fileContent.type == "chat-info") { if (fileContent.type == "chat-info") {
if (checkMatchesObjectStructure(fileContent, ChatInfoReference) == false) return; if (checkMatchesObjectStructure(fileContent, ChatInfoReference) == false) return;
this.chatModel.handleInfo(fileContent); this.chatModel.handleInfo(fileContent);
Vendored
+1 -1
View File
@@ -1,4 +1,4 @@
const VERSION = "2610 Beta 11" const VERSION = "2610 Beta 12"
function processUrl(event) { function processUrl(event) {
const url = event.request.url; const url = event.request.url;
+1 -1
View File
@@ -1 +1 @@
2610 Beta 11 2610 Beta 12
+2 -1
View File
@@ -285,11 +285,12 @@ export default class ChatModel {
// load // load
readonly loadInfo = (): void => { readonly loadInfo = (): void => {
const info: ChatInfoFileContent | null = this.storageModel.readStringifiable( let info: ChatInfoFileContent | null = this.storageModel.readStringifiable(
this.getInfoPath(), this.getInfoPath(),
ChatInfoReference, ChatInfoReference,
); );
this.info = (info || ChatModel.generateChatInfo("0", "0", Colors.Standard)); this.info = (info || ChatModel.generateChatInfo("0", "0", Colors.Standard));
this.storeInfo();
}; };
readonly handleInfo = (info: ChatInfoFileContent): void => { readonly handleInfo = (info: ChatInfoFileContent): void => {
+2
View File
@@ -67,6 +67,8 @@ export default class FileModel {
}; };
readonly handleFileContent = (fileContent: FileContent<string>): void => { readonly handleFileContent = (fileContent: FileContent<string>): void => {
console.log(fileContent.type);
if (fileContent.type == "chat-info") { if (fileContent.type == "chat-info") {
if (checkMatchesObjectStructure(fileContent, ChatInfoReference) == false) return; if (checkMatchesObjectStructure(fileContent, ChatInfoReference) == false) return;
this.chatModel.handleInfo(fileContent as ChatInfoFileContent); this.chatModel.handleInfo(fileContent as ChatInfoFileContent);