merge upstream
This commit is contained in:
commit
d8908ef2d8
1065 changed files with 32953 additions and 20092 deletions
|
|
@ -106,8 +106,8 @@ export default abstract class Channel {
|
|||
this.noteEntityService = noteEntityService;
|
||||
}
|
||||
|
||||
public send(payload: { type: string, body: JsonValue }): void
|
||||
public send(type: string, payload: JsonValue): void
|
||||
public send(payload: { type: string, body: JsonValue }): void;
|
||||
public send(type: string, payload: JsonValue): void;
|
||||
@bindThis
|
||||
public send(typeOrPayload: { type: string, body: JsonValue } | string, payload?: JsonValue) {
|
||||
const type = payload === undefined ? (typeOrPayload as { type: string, body: JsonValue }).type : (typeOrPayload as string);
|
||||
|
|
@ -166,4 +166,4 @@ export type MiChannelService<T extends boolean> = {
|
|||
requireCredential: T;
|
||||
kind: T extends true ? string : string | null | undefined;
|
||||
create: (id: string, connection: Connection) => Channel;
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue