feat: code adjustments

This commit is contained in:
Zamitto
2025-03-10 20:21:17 -03:00
parent 85efc23c25
commit d8a4eaaa66
5 changed files with 11 additions and 11 deletions

View File

@@ -81,14 +81,14 @@ export const publishNotificationUpdateReadyToInstall = async (
};
export const publishNewFriendRequestNotification = async () => {
const userPreferences = await db.get<string, UserPreferences>(
const userPreferences = await db.get<string, UserPreferences | null>(
levelKeys.userPreferences,
{
valueEncoding: "json",
}
);
if (!userPreferences.friendRequestNotificationsEnabled) return;
if (!userPreferences?.friendRequestNotificationsEnabled) return;
new Notification({
title: t("new_friend_request_title", {