Skip to content

Commit

Permalink
fix(client-electron): show release notes only once
Browse files Browse the repository at this point in the history
fixes #184
  • Loading branch information
marcincichocki authored Sep 16, 2021
1 parent 9dcfbce commit 75bcbdb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/electron/main/updater.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ import { Store } from './store/store';
export class BreachProtocolAutosolverUpdater {
private autoUpdate: boolean = null;

private wereReleseNotesShown = false;

constructor(
private store: Store,
private renderer: Electron.webContents,
Expand Down Expand Up @@ -82,8 +84,9 @@ export class BreachProtocolAutosolverUpdater {
}

private onUpdateNotAvailable(info: UpdateInfo) {
if (this.isFirstRun) {
if (this.isFirstRun && !this.wereReleseNotesShown) {
this.renderer.send('main:show-release-notes', info);
this.wereReleseNotesShown = true;
}

this.setUpdateStatus(UpdateStatus.UpdateNotAvailable);
Expand Down

0 comments on commit 75bcbdb

Please sign in to comment.