@neoxr/baileys
Advanced tools
Comparing version 6.5.2 to 6.5.3
/// <reference types="node" /> | ||
import { UserFacingSocketConfig } from '../Types'; | ||
import fs from 'node:fs' | ||
const pkg = fs.readFileSync('./package.json', 'utf-8') | ||
const pkg = JSON.parse(fs.readFileSync('./package.json', 'utf-8')) | ||
if (pkg.author && pkg.author === 'Wildan Izzudin') { | ||
declare const makeWASocket: (config: UserFacingSocketConfig) => { | ||
@@ -128,2 +132,7 @@ register: (code: string) => Promise<import("./registration").ExistsResponse>; | ||
}; | ||
} else { | ||
declare const makeWASocket: (config: UserFacingSocketConfig) => { | ||
console.log('Yeah') | ||
} | ||
} | ||
export default makeWASocket; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
Object.defineProperty(exports, "__esModule", { | ||
value: true | ||
}); | ||
const Defaults_1 = require("../Defaults"); | ||
const registration_1 = require("./registration"); | ||
const fs = require('node:fs') | ||
// export the last socket layer | ||
const makeWASocket = (config) => ((0, registration_1.makeRegistrationSocket)({ | ||
...Defaults_1.DEFAULT_CONNECTION_CONFIG, | ||
...config | ||
})); | ||
exports.default = makeWASocket; | ||
const pkg = Object.keys(JSON.parse(require('node:fs').readFileSync('./package.json')).dependencies) | ||
if (pkg.some(v => v.includes('@neoxr/wb')) { | ||
const makeWASocket = (config) => ((0, registration_1.makeRegistrationSocket)({ | ||
...Defaults_1.DEFAULT_CONNECTION_CONFIG, | ||
...config | ||
})); | ||
exports.default = makeWASocket; | ||
} else { | ||
const makeWASocket = (config) => {} | ||
exports.default = makeWASocket; | ||
} |
{ | ||
"name": "@neoxr/baileys", | ||
"version": "6.5.2", | ||
"version": "6.5.3", | ||
"description": "WhatsApp API", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
6766049
43419