Skip to content

Commit

Permalink
Merge pull request #199 from Madff386/develop
Browse files Browse the repository at this point in the history
Update titlebar.ts to remove use of fs module after refactor
  • Loading branch information
AlexTorresDev committed Oct 5, 2022
2 parents 05b3b6f + 9d4ff18 commit c6e3316
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/titlebar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
* Licensed under the MIT License. See License in the project root for license information.
*-------------------------------------------------------------------------------------------------------*/

import fs from 'fs';
import { Menu, ipcRenderer } from 'electron';
import { platform, PlatformToString, isLinux, isMacintosh, isWindows } from 'vs/base/common/platform';
import { Color, RGBA } from 'vs/base/common/color';
Expand Down Expand Up @@ -103,9 +102,7 @@ export default class Titlebar {

_loadIcons() {
if (this._options.icons) {
const icons = fs.readFileSync(this._options.icons, 'utf8');
const jsonIcons = JSON.parse(icons);
this._platformIcons = jsonIcons[PlatformToString(platform).toLocaleLowerCase()];
this._platformIcons = this._options.icons[PlatformToString(platform).toLocaleLowerCase()];
}
}

Expand Down

0 comments on commit c6e3316

Please sign in to comment.