Skip to content

Commit

Permalink
fix lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
mohitpubnub committed Jun 17, 2024
1 parent 3ca11b3 commit 90f21d0
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions dist/web/pubnub.js
Original file line number Diff line number Diff line change
Expand Up @@ -8964,8 +8964,8 @@

class SubscribeCapable {
subscribe(subscribeParameters) {
let timetoken = subscribeParameters === null || subscribeParameters === void 0 ? void 0 : subscribeParameters.timetoken;
this.pubnub.subscribe(Object.assign({ channels: this.channelNames, channelGroups: this.groupNames }, ((timetoken !== null && timetoken !== '') && { timetoken: timetoken })));
const timetoken = subscribeParameters === null || subscribeParameters === void 0 ? void 0 : subscribeParameters.timetoken;
this.pubnub.subscribe(Object.assign({ channels: this.channelNames, channelGroups: this.groupNames }, (timetoken !== null && timetoken !== '' && { timetoken: timetoken })));
}
unsubscribe() {
this.pubnub.unsubscribe({
Expand Down
2 changes: 1 addition & 1 deletion dist/web/pubnub.min.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions lib/entities/SubscribeCapable.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
exports.SubscribeCapable = void 0;
class SubscribeCapable {
subscribe(subscribeParameters) {
let timetoken = subscribeParameters === null || subscribeParameters === void 0 ? void 0 : subscribeParameters.timetoken;
this.pubnub.subscribe(Object.assign({ channels: this.channelNames, channelGroups: this.groupNames }, ((timetoken !== null && timetoken !== '') && { timetoken: timetoken })));
const timetoken = subscribeParameters === null || subscribeParameters === void 0 ? void 0 : subscribeParameters.timetoken;
this.pubnub.subscribe(Object.assign({ channels: this.channelNames, channelGroups: this.groupNames }, (timetoken !== null && timetoken !== '' && { timetoken: timetoken })));
}
unsubscribe() {
this.pubnub.unsubscribe({
Expand Down
6 changes: 3 additions & 3 deletions src/entities/SubscribeCapable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ export abstract class SubscribeCapable {
protected abstract pubnub: PubNub<unknown, unknown>;
protected abstract options?: SubscriptionOptions;

subscribe(subscribeParameters?:{timetoken?: string}) {
let timetoken = subscribeParameters?.timetoken;
subscribe(subscribeParameters?: { timetoken?: string }) {
const timetoken = subscribeParameters?.timetoken;
this.pubnub.subscribe({
channels: this.channelNames,
channelGroups: this.groupNames,
...((timetoken !== null && timetoken !== '') && { timetoken: timetoken }),
...(timetoken !== null && timetoken !== '' && { timetoken: timetoken }),
});
}
unsubscribe() {
Expand Down
2 changes: 1 addition & 1 deletion src/entities/commonTypes.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
export type SubscriptionOptions = {
export type SubscriptionOptions = {
receivePresenceEvents?: boolean;
};

0 comments on commit 90f21d0

Please sign in to comment.