mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-12-09 01:49:37 -06:00
style: fix lint formatting issues
This commit is contained in:
parent
930d32df3a
commit
04ac880fcc
@ -82,7 +82,7 @@ import { createId as cuid } from '@paralleldrive/cuid2';
|
||||
import { Instance, Message } from '@prisma/client';
|
||||
import { createJid } from '@utils/createJid';
|
||||
import { fetchLatestWaWebVersion } from '@utils/fetchLatestWaWebVersion';
|
||||
import {makeProxyAgent, makeProxyAgentUndici} from '@utils/makeProxyAgent';
|
||||
import { makeProxyAgent, makeProxyAgentUndici } from '@utils/makeProxyAgent';
|
||||
import { getOnWhatsappCache, saveOnWhatsappCache } from '@utils/onWhatsappCache';
|
||||
import { status } from '@utils/renderStatus';
|
||||
import { sendTelemetry } from '@utils/sendTelemetry';
|
||||
|
||||
@ -20,7 +20,18 @@ export type EmitData = {
|
||||
export interface EventControllerInterface {
|
||||
set(instanceName: string, data: any): Promise<any>;
|
||||
get(instanceName: string): Promise<any>;
|
||||
emit({ instanceName, origin, event, data, serverUrl, dateTime, sender, apiKey, local, extra }: EmitData): Promise<void>;
|
||||
emit({
|
||||
instanceName,
|
||||
origin,
|
||||
event,
|
||||
data,
|
||||
serverUrl,
|
||||
dateTime,
|
||||
sender,
|
||||
apiKey,
|
||||
local,
|
||||
extra,
|
||||
}: EmitData): Promise<void>;
|
||||
}
|
||||
|
||||
export class EventController {
|
||||
|
||||
@ -431,7 +431,13 @@ export class ChannelStartupService {
|
||||
return data;
|
||||
}
|
||||
|
||||
public async sendDataWebhook<T extends object = any>(event: Events, data: T, local = true, integration?: string[], extra?: Record<string, any>) {
|
||||
public async sendDataWebhook<T extends object = any>(
|
||||
event: Events,
|
||||
data: T,
|
||||
local = true,
|
||||
integration?: string[],
|
||||
extra?: Record<string, any>,
|
||||
) {
|
||||
const serverUrl = this.configService.get<HttpServer>('SERVER').URL;
|
||||
const tzoffset = new Date().getTimezoneOffset() * 60000; //offset in milliseconds
|
||||
const localISOTime = new Date(Date.now() - tzoffset).toISOString();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user