fix #2400 Check that the user is internet-connected before loading the getting started page

This commit is contained in:
Sofian Hnaide 2016-01-27 16:16:45 -08:00
parent 77d07b0156
commit 46234232d9
2 changed files with 8 additions and 1 deletions

View file

@ -32,7 +32,7 @@ export abstract class AbstractGettingStarted implements IWorkbenchContribution {
}
}
private handleWelcome(): void {
protected handleWelcome(): void {
let firstStartup = !this.storageService.get(AbstractGettingStarted.hideWelcomeSettingskey);
if (firstStartup && this.welcomePageURL) {

View file

@ -14,4 +14,11 @@ export class ElectronGettingStarted extends AbstractGettingStarted implements IW
protected openExternal(url: string) {
shell.openExternal(url);
}
protected handleWelcome(): void {
//make sure the user is online, otherwise refer to the next run to show the welcome page
if(navigator.onLine) {
super.handleWelcome();
}
}
}