This commit is contained in:
syuilo
2017-11-16 23:46:36 +09:00
parent 3d3309282e
commit a8c6d0ed90
12 changed files with 91 additions and 29 deletions

View File

@@ -17,6 +17,10 @@ class MisskeyEvent {
this.publish(`user-stream:${userId}`, type, typeof value === 'undefined' ? null : value);
}
public publishDriveStream(userId: ID, type: string, value?: any): void {
this.publish(`drive-stream:${userId}`, type, typeof value === 'undefined' ? null : value);
}
public publishPostStream(postId: ID, type: string, value?: any): void {
this.publish(`post-stream:${postId}`, type, typeof value === 'undefined' ? null : value);
}
@@ -46,6 +50,8 @@ const ev = new MisskeyEvent();
export default ev.publishUserStream.bind(ev);
export const publishDriveStream = ev.publishDriveStream.bind(ev);
export const publishPostStream = ev.publishPostStream.bind(ev);
export const publishMessagingStream = ev.publishMessagingStream.bind(ev);