Skip to content

Commit

Permalink
fix(general): tslint being applied in all sources.
Browse files Browse the repository at this point in the history
  • Loading branch information
rodrigorodriguez committed Apr 1, 2019
1 parent f0c7298 commit 895be68
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
20 changes: 10 additions & 10 deletions packages/azuredeployer.gbapp/dialogs/StartDialog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ export class StartDialog {

private static retrieveUsername() {
let value = GBConfigService.get('CLOUD_USERNAME');
if (value !== undefined) {
if (value === undefined) {
process.stdout.write(`${GBAdminService.GB_PROMPT}CLOUD_USERNAME:`);
value = scanf('%s').replace(/(\n|\r)+$/, '');
}
Expand All @@ -130,7 +130,7 @@ export class StartDialog {

private static retrievePassword() {
let password = GBConfigService.get('CLOUD_PASSWORD');
if (password !== undefined) {
if (password === undefined) {
process.stdout.write(`${GBAdminService.GB_PROMPT}CLOUD_PASSWORD:`);
password = scanf('%s').replace(/(\n|\r)+$/, '');
}
Expand All @@ -140,7 +140,7 @@ export class StartDialog {

private static retrieveBotId() {
let botId = GBConfigService.get('BOT_ID');
if (botId !== undefined) {
if (botId === undefined) {
process.stdout.write(
`${GBAdminService.GB_PROMPT}Choose a unique bot Id containing lowercase letters, digits or
dashes (cannot use dash as the first two or last one characters),
Expand All @@ -155,7 +155,7 @@ cannot start or end with or contain consecutive dashes and having 4 to 42 charac

private static retrieveAuthoringKey() {
let authoringKey = GBConfigService.get('NLP_AUTHORING_KEY');
if (authoringKey !== undefined) {
if (authoringKey === undefined) {
process.stdout.write(
`${
GBAdminService.GB_PROMPT
Expand All @@ -174,12 +174,12 @@ cannot start or end with or contain consecutive dashes and having 4 to 42 charac

private static retrieveAppId() {
let appId = GBConfigService.get('MARKETPLACE_ID');
process.stdout.write(
`Sorry, this part cannot be automated yet due to Microsoft schedule,
if (appId === undefined) {
process.stdout.write(
`Sorry, this part cannot be automated yet due to Microsoft schedule,
please go to https://apps.dev.microsoft.com/portal/register-app to
generate manually an App ID and App Secret.\n`
);
if (appId !== undefined) {
);
process.stdout.write('Generated Application Id (MARKETPLACE_ID):');
appId = scanf('%s').replace(/(\n|\r)+$/, '');
}
Expand All @@ -189,7 +189,7 @@ generate manually an App ID and App Secret.\n`

private static retrieveAppPassword() {
let appPassword = GBConfigService.get('MARKETPLACE_SECRET');
if (appPassword !== undefined) {
if (appPassword === undefined) {
process.stdout.write('Generated Password (MARKETPLACE_SECRET):');
appPassword = scanf('%s').replace(/(\n|\r)+$/, '');
}
Expand Down Expand Up @@ -217,7 +217,7 @@ generate manually an App ID and App Secret.\n`

private static retrieveLocation() {
let location = GBConfigService.get('CLOUD_LOCATION');
if (location !== undefined) {
if (location === undefined) {
process.stdout.write('CLOUD_LOCATION (eg. westus):');
location = scanf('%s');
}
Expand Down
4 changes: 2 additions & 2 deletions packages/azuredeployer.gbapp/services/AzureDeployerService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -477,15 +477,15 @@ export class AzureDeployerService implements IGBInstallationDeployer {
this.apiVersion
}`;
url = urlJoin(baseUrl, query);
req = AzureDeployerService.createRequestObject(url, accessToken, 'GET', JSON.stringify(parameters));
req = AzureDeployerService.createRequestObject(url, accessToken, 'POST', JSON.stringify(parameters));
const resChannel = await httpClient.sendRequest(req);
const key = JSON.parse(resChannel.bodyAsText).properties.properties.sites[0].key;
instance.webchatKey = key;
resolve(instance);
} catch (error) {
reject(error);
}
}, 20000);
}, 20000);
});
}

Expand Down
2 changes: 1 addition & 1 deletion packages/core.gbapp/services/GBDeployer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export class GBDeployer {
let totalPackages = 0;
const additionalPath = GBConfigService.get('ADDITIONAL_DEPLOY_PATH');
let paths = [GBDeployer.deployFolder];
if (additionalPath !== undefined) {
if (additionalPath !== undefined && additionalPath !== '') {
paths = paths.concat(additionalPath.toLowerCase().split(';'));
}
const botPackages: string[] = [];
Expand Down

0 comments on commit 895be68

Please sign in to comment.