mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-07-13 15:14:49 -06:00
fix: guard applyFormatting
This commit is contained in:
parent
39606240da
commit
f5f423eb74
@ -197,6 +197,9 @@ export class TypebotService extends BaseChatbotService<TypebotModel, any> {
|
||||
* Apply rich text formatting for TypeBot messages
|
||||
*/
|
||||
private applyFormatting(element: any): string {
|
||||
if (typeof element === 'string') return element;
|
||||
if (!element) return '';
|
||||
|
||||
let text = '';
|
||||
|
||||
if (element.text) {
|
||||
|
Loading…
Reference in New Issue
Block a user