Skip to content
This repository was archived by the owner on Jun 30, 2022. It is now read-only.

Commit f12a7c2

Browse files
authored
[botskills] update split and err (#2575)
1 parent 78b8cef commit f12a7c2

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

tools/botskills/src/utils/authenticationUtils.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ export class AuthenticationUtils {
116116
logger.message('Configuring Azure AD connection ...');
117117

118118
let connectionName: string = aadConfig.id;
119-
const newScopes: string[] = aadConfig.scopes.split(', ');
119+
const newScopes: string[] = aadConfig.scopes.split(',');
120120
let scopes: string[] = newScopes.slice(0);
121121

122122
// check for existing aad connection
@@ -257,18 +257,18 @@ export class AuthenticationUtils {
257257
} catch (err) {
258258
logger.warning(`Could not configure authentication connection automatically.`);
259259
if (currentCommand.length > 0) {
260-
logger.warning(`There was an error while executing the following command:\n\t${currentCommand.join(' ')}\n${err.message}`);
260+
logger.warning(`There was an error while executing the following command:\n\t${currentCommand.join(' ')}\n${err.message || err}`);
261261
logger.warning(`You must configure one of the following connection types MANUALLY in the Azure Portal:
262262
${manifest.authenticationConnections.map((authConn: IAuthenticationConnection) => authConn.serviceProviderId)
263263
.join(', ')}`);
264264
logger.warning(`For more information on setting up the authentication configuration manually go to:\n${this.docLink}`);
265265
} else if (manifest.authenticationConnections && manifest.authenticationConnections.length > 0) {
266-
logger.warning(`${err.message} You must configure one of the following connection types MANUALLY in the Azure Portal:
266+
logger.warning(`${err.message || err} You must configure one of the following connection types MANUALLY in the Azure Portal:
267267
${manifest.authenticationConnections.map((authConn: IAuthenticationConnection) => authConn.serviceProviderId)
268268
.join(', ')}`);
269269
logger.warning(`For more information on setting up the authentication configuration manually go to:\n${this.docLink}`);
270270
} else {
271-
logger.warning(err.message);
271+
logger.warning(err.message || err);
272272
}
273273

274274
return false;

0 commit comments

Comments
 (0)