globalEventの名前を明確にする
This commit is contained in:
parent
41a6f6271a
commit
6b43154094
|
|
@ -28,7 +28,7 @@ export function testNotification(type: 'client' | 'server'): void {
|
|||
os.api('notifications/test-notification');
|
||||
break;
|
||||
case 'client':
|
||||
globalEvents.emit('notification', notification);
|
||||
globalEvents.emit('clientNotification', notification);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@ function onNotification(notification: Misskey.entities.Notification, isClient: b
|
|||
if ($i) {
|
||||
const connection = useStream().useChannel('main', null, 'UI');
|
||||
connection.on('notification', onNotification);
|
||||
globalEvents.on('notification', notification => onNotification(notification, true));
|
||||
globalEvents.on('clientNotification', notification => onNotification(notification, true));
|
||||
|
||||
//#region Listen message from SW
|
||||
if ('serviceWorker' in navigator) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue