Skip to content

Commit

Permalink
fixed deepscan issues
Browse files Browse the repository at this point in the history
  • Loading branch information
akanshaaa19 committed Jul 22, 2024
1 parent 13d764b commit ba7eb1c
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ export const ChatTemplates = ({
const translationsObj: any = [];
const sessionTemplates = data?.sessionTemplates;

sessionTemplates.forEach((obj: any) => {
sessionTemplates?.forEach((obj: any) => {
const translations = JSON.parse(obj.translations);
// add translation in list
if (Object.keys(translations).length > 0) {
Expand All @@ -119,7 +119,7 @@ export const ChatTemplates = ({
}
});

const templateObj = [...sessionTemplates, ...translationsObj];
const templateObj = sessionTemplates ? [...sessionTemplates, ...translationsObj] : [];
const interactiveObj = interactives ? [...interactives?.interactiveTemplates] : [];

let listItems;
Expand Down

0 comments on commit ba7eb1c

Please sign in to comment.