Skip to content

Commit

Permalink
docs: show detailed error message in custom api template (#11093)
Browse files Browse the repository at this point in the history
  • Loading branch information
KennethBWSong committed Mar 18, 2024
1 parent 8c9a1e3 commit 9e105db
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions templates/js/custom-copilot-rag-custom-api/src/adapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,7 @@ const onTurnErrorHandler = async (context, error) => {
);

// Send a message to the user
await context.sendActivity("The bot encountered an error or bug.");
await context.sendActivity("To continue to run this bot, please fix the bot source code.");
await context.sendActivity(`The bot encountered an error or bug: ${error.message}`);
}
};

Expand Down
3 changes: 1 addition & 2 deletions templates/ts/custom-copilot-rag-custom-api/src/adapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ const onTurnErrorHandler = async (context, error) => {
);

// Send a message to the user
await context.sendActivity("The bot encountered an error or bug.");
await context.sendActivity("To continue to run this bot, please fix the bot source code.");
await context.sendActivity(`The bot encountered an error or bug: ${error.message}`);
}
};

Expand Down

0 comments on commit 9e105db

Please sign in to comment.