Skip to content

Commit

Permalink
feat: Use default browser promise instead bluebird
Browse files Browse the repository at this point in the history
  • Loading branch information
= committed Sep 27, 2019
1 parent 4e0af76 commit ebe82d5
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
5 changes: 2 additions & 3 deletions src/Lime/Protocol/Client/Channel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import Command, { CommandListener, CommandMethod, CommandStatus } from "../Comma
import Notification, { NotificationListener, NotificationEvent } from "../Notification";
import Session, { SessionListener, SessionState } from "../Session";
import Transport from "../Network/Transport";
import * as Promise from "bluebird";

export interface MessageChannel extends MessageListener {
sendMessage(message: Message): void;
Expand All @@ -23,7 +22,7 @@ export interface SessionChannel extends SessionListener {
}

export interface CommandProcessor extends CommandListener {
processCommand(command: Command): Promise<Command>;
processCommand(command: Command): Promise<any>;
}

abstract class Channel implements MessageChannel, CommandChannel, NotificationChannel, SessionChannel, CommandProcessor {
Expand Down Expand Up @@ -105,7 +104,7 @@ abstract class Channel implements MessageChannel, CommandChannel, NotificationCh
}
abstract onMessage(message: Message): void;

processCommand(command: Command, timeout = this.commandTimeout): Promise<Command> {
processCommand(command: Command, timeout = this.commandTimeout): Promise<any> {
const responsePromise = new Promise(resolve => {
this._commandResolves[command.id] = resolve;
});
Expand Down
1 change: 0 additions & 1 deletion src/Lime/Protocol/Client/ClientChannel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import Session, { SessionCompression, SessionEncryption, SessionState } from "..
import Channel from "./Channel";
import Transport from "../Network/Transport";
import Authentication from "../Security/Authentication";
import * as Promise from "bluebird";

export default class ClientChannel extends Channel {

Expand Down
1 change: 0 additions & 1 deletion src/Lime/Protocol/Network/Transport.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import Envelope, { EnvelopeListener } from "../Envelope";
import { SessionCompression, SessionEncryption } from "../Session";
import * as Promise from "bluebird";

interface Transport extends EnvelopeListener {
open(uri: string): Promise<void>;
Expand Down

0 comments on commit ebe82d5

Please sign in to comment.