mirror of
https://github.com/rubickCenter/rubick
synced 2025-06-17 17:16:57 +08:00
ref: 优化window读取系统应用
This commit is contained in:
parent
d047119076
commit
9242f17cde
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "rubick2",
|
||||
"version": "0.0.4",
|
||||
"version": "0.0.5",
|
||||
"author": "muwoo <2424880409@qq.com>",
|
||||
"description": "An electron-vue project",
|
||||
"license": null,
|
||||
|
@ -17,7 +17,13 @@ const getico = app =>{
|
||||
try {
|
||||
const buffer = fileIcon(app.desc, 32);
|
||||
const iconpath = path.join(icondir, `${app.name}.png`);
|
||||
fs.writeFileSync(iconpath, buffer, 'base64');
|
||||
|
||||
fs.exists(iconpath, exists => {
|
||||
if (!exists) {
|
||||
fs.writeFile(iconpath, buffer, 'base64', () => {});
|
||||
}
|
||||
});
|
||||
|
||||
} catch(e) {
|
||||
console.log(e, app.desc);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user