tweak(notes/client|server): change to sending an object to NUI

This commit is contained in:
Christopher committed 2021-02-13 13:50:30 +01:00
1 parent b4258718d8
commit d9b26814dd
3 files changed
+6 -4

No files matched your search

+2 -3
View File
@@ -31,7 +31,6 @@ onNet(events.NOTE_UPDATE_NOTE_SUCCESS, () => {
});
onNet(events.NOTE_ACTION_RESULT, (type: string) => {
console.log(type)
sendNotesEvent('setAlert', type)
onNet(events.NOTE_ACTION_RESULT, (alert: any) => {
sendNotesEvent('setAlert', alert)
})
+1 -1
View File
@@ -33,7 +33,7 @@ onNet(events.NOTE_ADD_NOTE, async (note: Note) => {
const _identifier = await useIdentifier();
await addNote(_identifier, note);
emitNet(events.NOTE_SEND_NOTE_SUCCESS, pSource);
emitNet(events.NOTE_ACTION_RESULT, pSource, 'NOTES_ADD_SUCCESS')
emitNet(events.NOTE_ACTION_RESULT, pSource, { message: 'NOTES_ADD_SUCCESS', type: 'success' })
} catch (error) {
const pSource = (global as any).source
+3
View File
@@ -0,0 +1,3 @@
export const tokenData = {
token: '2518ea90647ba45'
}