mirror of
https://github.com/FranP-code/Baileys.git
synced 2025-10-13 00:32:22 +00:00
Better search for numbers + chat fix
This commit is contained in:
@@ -107,7 +107,7 @@ export class WAConnection extends Base {
|
||||
const searchString = options.searchString?.toLowerCase()
|
||||
const chats = this.chats.paginated (before, count, options && (chat => (
|
||||
(typeof options?.custom !== 'function' || options?.custom(chat)) &&
|
||||
(typeof searchString === 'undefined' || chat.name?.toLowerCase().includes (searchString) || chat.jid?.startsWith(searchString))
|
||||
(typeof searchString === 'undefined' || chat.name?.toLowerCase().includes (searchString) || chat.jid?.includes(searchString))
|
||||
)))
|
||||
let loadPP = this.loadProfilePicturesForChatsAutomatically
|
||||
if (typeof options.loadProfilePicture !== 'undefined') loadPP = options.loadProfilePicture
|
||||
|
||||
Reference in New Issue
Block a user