fix: add connectionRequests to notification schema, remove dead notifyPeerRequests
This commit is contained in:
parent
2aa29ba64b
commit
bd07172093
2 changed files with 3 additions and 5 deletions
|
|
@ -380,7 +380,6 @@ const formData = reactive({
|
|||
// Notifications
|
||||
notifyEvents: true,
|
||||
notifyUpdates: true,
|
||||
notifyPeerRequests: true,
|
||||
notifyConnectionRequests: true,
|
||||
});
|
||||
|
||||
|
|
@ -437,8 +436,7 @@ const loadProfile = () => {
|
|||
const notifs = memberData.value.notifications || {};
|
||||
formData.notifyEvents = notifs.events ?? true;
|
||||
formData.notifyUpdates = notifs.updates ?? true;
|
||||
formData.notifyPeerRequests = notifs.peerRequests ?? true;
|
||||
formData.notifyConnectionRequests = notifs.connectionRequests ?? true;
|
||||
formData.notifyConnectionRequests = notifs.connectionRequests ?? notifs.peerRequests ?? true;
|
||||
|
||||
// Store initial state for change detection
|
||||
initialData.value = JSON.parse(JSON.stringify(formData));
|
||||
|
|
@ -461,7 +459,6 @@ const handleSubmit = async () => {
|
|||
notifications: {
|
||||
events: formData.notifyEvents,
|
||||
updates: formData.notifyUpdates,
|
||||
peerRequests: formData.notifyPeerRequests,
|
||||
connectionRequests: formData.notifyConnectionRequests,
|
||||
},
|
||||
},
|
||||
|
|
|
|||
|
|
@ -38,7 +38,8 @@ export const memberProfileUpdateSchema = z.object({
|
|||
notifications: z.object({
|
||||
events: z.boolean().optional(),
|
||||
updates: z.boolean().optional(),
|
||||
peerRequests: z.boolean().optional()
|
||||
peerRequests: z.boolean().optional(),
|
||||
connectionRequests: z.boolean().optional()
|
||||
}).optional(),
|
||||
pronounsPrivacy: privacyEnum.optional(),
|
||||
timeZonePrivacy: privacyEnum.optional(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue