File tree 2 files changed +4
-4
lines changed
libraries/botbuilder-dialogs
2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -264,7 +264,7 @@ export class OAuthPrompt extends Dialog {
264
264
private async sendOAuthCardAsync ( context : TurnContext , prompt ?: string | Partial < Activity > ) : Promise < void > {
265
265
// Validate adapter type
266
266
if ( ! ( 'getUserToken' in context . adapter ) ) {
267
- throw new Error ( `OAuthPrompt.prompt (): not supported for the current adapter.` ) ;
267
+ throw new Error ( `OAuthPrompt.sendOAuthCardAsync (): not supported for the current adapter.` ) ;
268
268
}
269
269
270
270
// Initialize outgoing message
@@ -364,8 +364,8 @@ export class OAuthPrompt extends Dialog {
364
364
// Token Exchange not supported in the adapter
365
365
await context . sendActivity ( this . getTokenExchangeInvokeResponse (
366
366
StatusCodes . BAD_GATEWAY ,
367
- 'The bot\'s BotAdapter does not support token exchange operations. Ensure the bot\'s Adapter supports the ITokenExchangeProvider interface.' ) ) ;
368
- throw new Error ( 'OAuthPrompt.recognize (): not supported by the current adapter' ) ;
367
+ 'The bot\'s BotAdapter does not support token exchange operations. Ensure the bot\'s Adapter supports the ExtendedUserTokenProvider interface.' ) ) ;
368
+ throw new Error ( 'OAuthPrompt.recognizeToken (): not supported by the current adapter' ) ;
369
369
} else {
370
370
// No errors. Proceed with token exchange
371
371
const extendedUserTokenProvider : ExtendedUserTokenProvider = context . adapter as ExtendedUserTokenProvider ;
Original file line number Diff line number Diff line change @@ -319,7 +319,7 @@ describe('OAuthPrompt', function() {
319
319
try {
320
320
await prompt . sendOAuthCardAsync ( context ) ;
321
321
} catch ( e ) {
322
- assert . strictEqual ( e . message , `OAuthPrompt.prompt (): not supported for the current adapter.` ) ;
322
+ assert . strictEqual ( e . message , `OAuthPrompt.sendOAuthCardAsync (): not supported for the current adapter.` ) ;
323
323
}
324
324
} ) ;
325
325
You can’t perform that action at this time.
0 commit comments