refactor: update import statements to use .js extensions
- Changed all import statements across the project to include the .js extension for consistency and to comply with ES module standards. - Updated imports in various files including bootstrap.ts, shutdown.ts, config.ts, and many others. - Ensured that all related modules and types are correctly imported with the new extension.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { EndBehaviorType, type VoiceReceiver } from "@discordjs/voice";
|
||||
import { config } from "../config";
|
||||
import { config } from "../config.js";
|
||||
|
||||
export interface AudioStreamHandlers {
|
||||
onPacket: (chunk: Buffer) => void;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { createRequire } from "node:module";
|
||||
import * as prism from "prism-media";
|
||||
import { config } from "../config";
|
||||
import { config } from "../config.js";
|
||||
|
||||
const require = createRequire(import.meta.url);
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import path from "node:path";
|
||||
import type { Client, VoiceChannel } from "discord.js-selfbot-v13";
|
||||
import { config } from "../config";
|
||||
import type { SegmentMetadata, SegmentState, UserMetadata } from "../types";
|
||||
import { config } from "../config.js";
|
||||
import type { SegmentMetadata, SegmentState, UserMetadata } from "../types.js";
|
||||
|
||||
export async function collectUserMetadata(
|
||||
client: Client,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import fs from "node:fs";
|
||||
import path from "node:path";
|
||||
import * as prism from "prism-media";
|
||||
import type { SegmentState } from "../types";
|
||||
import type { SegmentState } from "../types.js";
|
||||
|
||||
export function buildSegmentPaths(
|
||||
userDir: string,
|
||||
|
||||
@@ -3,8 +3,8 @@ import path from "node:path";
|
||||
import {
|
||||
buildMuxFfmpegArgs,
|
||||
runFfmpeg as defaultRunFfmpeg,
|
||||
} from "../audio/ffmpegProcess";
|
||||
import type { UserMetadata } from "../types";
|
||||
} from "../audio/ffmpegProcess.js";
|
||||
import type { UserMetadata } from "../types.js";
|
||||
|
||||
export type SessionRecordingStatus =
|
||||
| "pending"
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
import fs from "node:fs";
|
||||
import path from "node:path";
|
||||
import { config } from "../config";
|
||||
import { config } from "../config.js";
|
||||
import {
|
||||
insertVoiceRecording,
|
||||
updateVoiceRecordingAsFailed,
|
||||
updateVoiceRecordingAsUploaded,
|
||||
} from "../database/voiceRecordingRepo";
|
||||
import { createChildLogger } from "../logger";
|
||||
import { uploadToTele } from "../uploader/teleUpload";
|
||||
} from "../database/voiceRecordingRepo.js";
|
||||
import { createChildLogger } from "../logger.js";
|
||||
import { uploadToTele } from "../uploader/teleUpload.js";
|
||||
|
||||
const logger = createChildLogger("recording-uploader");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user