Skip to content

Commit

Permalink
Merge pull request howdyai#1986 from alex-ubitec/patch-2
Browse files Browse the repository at this point in the history
Result is not necessarily defined here
  • Loading branch information
benbrown authored Aug 25, 2020
2 parents 532b5e5 + 6d05622 commit 62dc012
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/botkit/src/conversation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -967,7 +967,7 @@ export class BotkitConversation<O extends object = {}> extends Dialog<O> {
const index = step.index;
const thread_name = step.thread;
const result = step.result;
const response = result.text || (typeof (result) === 'string' ? result : null);
const response = result == null ? null : (result.text || (typeof (result) === 'string' ? result : null));

// spawn a bot instance so devs can use API or other stuff as necessary
const bot = await this._controller.spawn(dc);
Expand Down

0 comments on commit 62dc012

Please sign in to comment.