Skip to content

Commit

Permalink
organised files and directories for presence
Browse files Browse the repository at this point in the history
  • Loading branch information
mohitpubnub committed Aug 18, 2023
1 parent 701a44f commit b377b3c
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { PubNubError } from '../../core/components/endpoint';
import { asyncHandler, Dispatcher, Engine } from '../core';
import * as effects from './presence_effects'
import * as events from './presence_events'
import * as effects from './effects'
import * as events from './events'


export type Dependencies = {
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { PubNubError } from "../core/components/endpoint";
import { createEvent, MapOf } from "./core";
import { PubNubError } from "../../core/components/endpoint";
import { createEvent, MapOf } from "../core";

export const disconnect = createEvent('DISCONNECT', () => ({}));

Expand Down
6 changes: 3 additions & 3 deletions src/event-engine/presence/presence.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Dispatcher, Engine } from "../core"
import * as events from "./presence_events"
import * as effects from "./presence_effects"
import { Dependencies, PresenceEventEngineDispatcher } from "./presence_dispatcher";
import * as events from "./events"
import * as effects from "./effects"
import { Dependencies, PresenceEventEngineDispatcher } from "./dispatcher";

export class PresenceEventEngine {
private engine: Engine<events.Events, effects.Effects> = new Engine();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { State } from '../../core/state';
import { Events, timesUp } from '../presence_events';
import { Effects } from '../presence_effects';
import { Events, timesUp } from '../events';
import { Effects } from '../effects';
import { HeartbeatingState } from './heartbeating';

export type HeartbeatCooldownStateContext = {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { State } from '../core/state';

Check failure on line 1 in src/event-engine/presence/states/heartbeat_inactive.ts

View workflow job for this annotation

GitHub Actions / Integration and Unit tests (12, ci:node)

Cannot find module '../core/state' or its corresponding type declarations.

Check failure on line 1 in src/event-engine/presence/states/heartbeat_inactive.ts

View workflow job for this annotation

GitHub Actions / Integration and Unit tests (14, ci:node)

Cannot find module '../core/state' or its corresponding type declarations.

Check failure on line 1 in src/event-engine/presence/states/heartbeat_inactive.ts

View workflow job for this annotation

GitHub Actions / Integration and Unit tests (16, ci:node)

Cannot find module '../core/state' or its corresponding type declarations.

Check failure on line 1 in src/event-engine/presence/states/heartbeat_inactive.ts

View workflow job for this annotation

GitHub Actions / Integration and Unit tests (16, ci:web)

Cannot find module '../core/state' or its corresponding type declarations.
import { Effects } from '../presence_effects';
import { Events, joined } from '../presence_events';
import { Effects } from '../effects';
import { Events, joined } from '../events';
import { HeartbeatingState } from './heartbeating';

export const HeartbeatInactiveState = new State<void, Events, Effects>('HEARTBEAT_INACTIVE');
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { State } from '../../core/state';
import { Events } from '../presence_events';
import { Effects } from '../presence_effects';
import { Events } from '../events';
import { Effects } from '../effects';

export type HeartbeatReconnectingStateContext = {
channels: string[];
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { State } from '../../core/state';
import { Events, heartbeatFailure, heartbeatSuccess, joined, left } from '../presence_events';
import { Effects, heartbeat, leave } from '../presence_effects';
import { Events, heartbeatFailure, heartbeatSuccess, joined, left } from '../events';
import { Effects, heartbeat, leave } from '../effects';
import { HeartbeatCooldownState } from './heartbeat_cooldown';
import { HearbeatReconnectingState } from './heartbeat_reconnecting';

Expand Down

0 comments on commit b377b3c

Please sign in to comment.