mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2026-01-10 13:52:20 -06:00
Merge branch 'main' into bugfix/waiting-for-message
This commit is contained in:
@@ -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 } 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';
|
||||
@@ -616,7 +616,7 @@ export class BaileysStartupService extends ChannelStartupService {
|
||||
const proxyUrls = text.split('\r\n');
|
||||
const rand = Math.floor(Math.random() * Math.floor(proxyUrls.length));
|
||||
const proxyUrl = 'http://' + proxyUrls[rand];
|
||||
options = { agent: makeProxyAgent(proxyUrl), fetchAgent: makeProxyAgent(proxyUrl) };
|
||||
options = { agent: makeProxyAgent(proxyUrl), fetchAgent: makeProxyAgentUndici(proxyUrl) };
|
||||
} catch {
|
||||
this.localProxy.enabled = false;
|
||||
}
|
||||
@@ -629,7 +629,7 @@ export class BaileysStartupService extends ChannelStartupService {
|
||||
username: this.localProxy.username,
|
||||
password: this.localProxy.password,
|
||||
}),
|
||||
fetchAgent: makeProxyAgent({
|
||||
fetchAgent: makeProxyAgentUndici({
|
||||
host: this.localProxy.host,
|
||||
port: this.localProxy.port,
|
||||
protocol: this.localProxy.protocol,
|
||||
|
||||
Reference in New Issue
Block a user