remove upgrader

This commit is contained in:
marlon-erler
2026-09-27 01:58:06 +02:00
parent 6bde9e0627
commit 5ac0a54458
5 changed files with 14 additions and 304 deletions
+7 -7
View File
@@ -182,7 +182,7 @@ export default class ChatModel {
readonly getSendingData = (): [string, string, string] => {
const senderName: string = this.settingsModel.username || "?";
const id: string = this.settingsModel.userid;
const id: string = this.settingsModel.userid;
const allChannels: string[] = [this.id];
for (const secondaryChannel of this.info.secondaryChannels) {
@@ -203,7 +203,7 @@ export default class ChatModel {
const chatMessage: ChatMessage = await ChatModel.createChatMessage(
combinedChannel,
senderId,
senderId,
senderName,
this.info.encryptionKey,
body,
@@ -240,7 +240,7 @@ export default class ChatModel {
const reaction = ChatModel.createMessageReaction(
messageId,
senderId,
senderId,
content,
isDeleting,
);
@@ -396,7 +396,7 @@ export default class ChatModel {
static createChatMessage = async (
channel: string,
sender: string,
senderId: string,
senderId: string,
encryptionKey: string,
body: string,
inlineReplyId?: string,
@@ -409,7 +409,7 @@ export default class ChatModel {
channel,
sender,
senderId,
senderId,
body,
dateSent: createTimestamp(),
inlineReplyId,
@@ -438,7 +438,7 @@ export default class ChatModel {
static createMessageReaction = (
messageId: string,
senderId: string,
senderId: string,
content: ReactionSymbols,
isDeleting: boolean,
): ChatMessageReaction => {
@@ -449,7 +449,7 @@ export default class ChatModel {
fileId: ChatModel.createMessageReactionId(messageId, senderId),
messageId,
senderId,
senderId,
content,
isDeleting,
};
+6 -6
View File
@@ -1,5 +1,5 @@
import {UUID} from "../../react";
import StorageModel, { StorageModelSubPaths, filePaths } from "./storageModel";
import { UUID } from "../../react";
export default class SettingsModel {
readonly storageModel: StorageModel;
@@ -27,7 +27,7 @@ export default class SettingsModel {
this.userid = newValue;
this.storeSetting("userid", newValue);
};
readonly setName = (newValue: string): void => {
this.username = newValue;
this.storeSetting("username", newValue);
@@ -58,12 +58,12 @@ export default class SettingsModel {
);
return this.storageModel.read(path);
};
readonly loadId = (): void => {
const content: string | null = this.readSetting("userid");
const id = content ?? UUID();
const id = content ?? UUID();
if (content) this.userid = content;
else this.setId(id);
else this.setId(id);
};
readonly loadUsername = (): void => {
@@ -90,7 +90,7 @@ export default class SettingsModel {
constructor(storageModel: StorageModel) {
this.storageModel = storageModel;
this.loadId();
this.loadId();
this.loadUsername();
this.loadFirstDayofWeek();
this.loadLanguage();
+1 -1
View File
@@ -306,7 +306,7 @@ export const filePaths = {
settingsModel: {
username: ["user-name"],
userid: ["user-id"],
userid: ["user-id"],
firstDayOfWeek: ["first-day-of-week"],
language: ["language"],
theme: ["theme"],