🚚 Move chatClient, pubSubClient and webServer to helpers
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
import { getApiClient, getAuthProvider } from "../helpers/twitch";
|
||||
import { getApiClient, getAuthProvider } from "./twitch";
|
||||
|
||||
import { ChatClient } from "twitch-chat-client";
|
||||
import { sockets } from "../webServer";
|
||||
import { start } from "../helpers/scheduledActions";
|
||||
import { sockets } from "./webServer";
|
||||
import { start } from "./scheduledActions";
|
||||
|
||||
let chatClient: ChatClient;
|
||||
|
@@ -1,7 +1,7 @@
|
||||
import { PubSubClient, PubSubRedemptionMessage } from "twitch-pubsub-client";
|
||||
import { broadcast, chatClient, say } from "../chatClient";
|
||||
import { getApiClient, getUsernameFromId } from "../helpers/twitch";
|
||||
import { saveScheduledActions, scheduledActions } from "../helpers/scheduledActions";
|
||||
import { broadcast, chatClient, say } from "./chatClient";
|
||||
import { getApiClient, getUsernameFromId } from "./twitch";
|
||||
import { saveScheduledActions, scheduledActions } from "./scheduledActions";
|
||||
|
||||
import { UserIdResolvable } from "twitch";
|
||||
|
@@ -1,5 +1,5 @@
|
||||
import { promises as fs } from "fs";
|
||||
import { handleClientAction } from "../chatClient";
|
||||
import { handleClientAction } from "./chatClient";
|
||||
import { resolve } from "path";
|
||||
|
||||
export {
|
||||
|
@@ -1,12 +1,12 @@
|
||||
import { IncomingMessage, Server } from "http";
|
||||
import { broadcast, handleClientAction } from "../chatClient";
|
||||
import { saveScheduledActions, scheduledActions } from "../helpers/scheduledActions";
|
||||
import { broadcast, handleClientAction } from "./chatClient";
|
||||
import { saveScheduledActions, scheduledActions } from "./scheduledActions";
|
||||
|
||||
import { AddressInfo } from "net";
|
||||
import { Socket } from "net";
|
||||
import WebSocket from "ws";
|
||||
import express from "express";
|
||||
import { isDevelopment } from "../helpers/util";
|
||||
import { isDevelopment } from "./util";
|
||||
import { join } from "path";
|
||||
|
||||
const app = express();
|
@@ -1,6 +1,6 @@
|
||||
import { connect } from "./chatClient";
|
||||
import { listen } from "./webServer";
|
||||
import { registerUserListener } from "./pubSubClient";
|
||||
import { connect } from "./helpers/chatClient";
|
||||
import { listen } from "./helpers/webServer";
|
||||
import { registerUserListener } from "./helpers/pubSubClient";
|
||||
|
||||
const channel = "alexbcberio";
|
||||
|
||||
|
Reference in New Issue
Block a user