mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-07-23 04:22:02 -06:00
fix: reorder imports to resolve linting issues
Reordered imports in multiple files to resolve linting issues and improve code readability. This change does not impact the functionality but ensures the code adheres to the project's coding standards.
This commit is contained in:
parent
5b47bc9ef0
commit
975b3ee528
@ -8,8 +8,8 @@ import ChatwootClient, {
|
||||
inbox,
|
||||
} from '@figuro/chatwoot-sdk';
|
||||
import { request as chatwootRequest } from '@figuro/chatwoot-sdk/dist/core/request';
|
||||
import { proto } from 'baileys';
|
||||
import axios from 'axios';
|
||||
import { proto } from 'baileys';
|
||||
import FormData from 'form-data';
|
||||
import { createReadStream, unlinkSync, writeFileSync } from 'fs';
|
||||
import Jimp from 'jimp';
|
||||
@ -444,8 +444,7 @@ export class ChatwootService {
|
||||
const searchableFields = this.getSearchableFields();
|
||||
|
||||
// eslint-disable-next-line prettier/prettier
|
||||
if(contacts.length === 2 && this.getClientCwConfig().merge_brazil_contacts && query.startsWith('+55')){
|
||||
|
||||
if (contacts.length === 2 && this.getClientCwConfig().merge_brazil_contacts && query.startsWith('+55')) {
|
||||
const contact = this.mergeBrazilianContacts(contacts);
|
||||
if (contact) {
|
||||
return contact;
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { WASocket } from 'baileys';
|
||||
import axios from 'axios';
|
||||
import { WASocket } from 'baileys';
|
||||
import { execSync } from 'child_process';
|
||||
import { isURL } from 'class-validator';
|
||||
import EventEmitter2 from 'eventemitter2';
|
||||
|
@ -1,5 +1,6 @@
|
||||
import ffmpegPath from '@ffmpeg-installer/ffmpeg';
|
||||
import { Boom } from '@hapi/boom';
|
||||
import axios from 'axios';
|
||||
import makeWASocket, {
|
||||
AnyMessageContent,
|
||||
BufferedEventData,
|
||||
@ -38,7 +39,6 @@ import makeWASocket, {
|
||||
} from 'baileys';
|
||||
import { Label } from 'baileys/lib/Types/Label';
|
||||
import { LabelAssociation } from 'baileys/lib/Types/LabelAssociation';
|
||||
import axios from 'axios';
|
||||
import { exec } from 'child_process';
|
||||
import { isBase64, isURL } from 'class-validator';
|
||||
import EventEmitter2 from 'eventemitter2';
|
||||
@ -253,8 +253,8 @@ export class BaileysStartupService extends ChannelStartupService {
|
||||
this.logger.verbose('Getting profile status');
|
||||
const status = await this.client.fetchStatus(this.instance.wuid);
|
||||
|
||||
this.logger.verbose(`Profile status: ${status.status}`);
|
||||
return status.status;
|
||||
this.logger.verbose(`Profile status: ${status[0]?.status}`);
|
||||
return status[0]?.status;
|
||||
}
|
||||
|
||||
public get profilePictureUrl() {
|
||||
@ -1737,7 +1737,7 @@ export class BaileysStartupService extends ChannelStartupService {
|
||||
this.logger.verbose('Getting status');
|
||||
return {
|
||||
wuid: jid,
|
||||
status: (await this.client.fetchStatus(jid))?.status,
|
||||
status: (await this.client.fetchStatus(jid))[0]?.status,
|
||||
};
|
||||
} catch (error) {
|
||||
this.logger.verbose('Status not found');
|
||||
|
@ -1,11 +1,4 @@
|
||||
import {
|
||||
AuthenticationCreds,
|
||||
AuthenticationState,
|
||||
BufferJSON,
|
||||
initAuthCreds,
|
||||
proto,
|
||||
SignalDataTypeMap,
|
||||
} from 'baileys';
|
||||
import { AuthenticationCreds, AuthenticationState, BufferJSON, initAuthCreds, proto, SignalDataTypeMap } from 'baileys';
|
||||
|
||||
import { configService, Database } from '../config/env.config';
|
||||
import { Logger } from '../config/logger.config';
|
||||
|
@ -34,14 +34,7 @@
|
||||
* └──────────────────────────────────────────────────────────────────────────────┘
|
||||
*/
|
||||
|
||||
import {
|
||||
AuthenticationCreds,
|
||||
AuthenticationState,
|
||||
BufferJSON,
|
||||
initAuthCreds,
|
||||
proto,
|
||||
SignalDataTypeMap,
|
||||
} from 'baileys';
|
||||
import { AuthenticationCreds, AuthenticationState, BufferJSON, initAuthCreds, proto, SignalDataTypeMap } from 'baileys';
|
||||
import { isNotEmpty } from 'class-validator';
|
||||
|
||||
import { ProviderFiles } from '../api/provider/sessions';
|
||||
|
@ -1,10 +1,4 @@
|
||||
import {
|
||||
AuthenticationCreds,
|
||||
AuthenticationState,
|
||||
initAuthCreds,
|
||||
proto,
|
||||
SignalDataTypeMap,
|
||||
} from 'baileys';
|
||||
import { AuthenticationCreds, AuthenticationState, initAuthCreds, proto, SignalDataTypeMap } from 'baileys';
|
||||
|
||||
import { CacheService } from '../api/services/cache.service';
|
||||
import { Logger } from '../config/logger.config';
|
||||
|
Loading…
Reference in New Issue
Block a user