Merge pull request #1536 from Daquisu/fix-fetchStatusMessage-params

Update `fetchStatusMessage` to handle empty offset / page
This commit is contained in:
Davidson Gomes 2025-06-03 12:40:14 -03:00 committed by GitHub
commit e469dc132f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -677,6 +677,14 @@ export class ChannelStartupService {
}
public async fetchStatusMessage(query: any) {
if (!query?.offset) {
query.offset = 50;
}
if (!query?.page) {
query.page = 1;
}
return await this.prismaRepository.messageUpdate.findMany({
where: {
instanceId: this.instanceId,