mirror of
https://github.com/Kuingsmile/PicList.git
synced 2026-05-06 20:42:57 +08:00
✨ Feature(custom): ensure dir exist before open
This commit is contained in:
@@ -185,9 +185,10 @@ export default [
|
|||||||
if (inStorePath) {
|
if (inStorePath) {
|
||||||
dirPath = path.join(STORE_PATH, dirPath || '')
|
dirPath = path.join(STORE_PATH, dirPath || '')
|
||||||
}
|
}
|
||||||
if (!dirPath || !fs.existsSync(dirPath)) {
|
if (!dirPath) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
fs.ensureDirSync(dirPath)
|
||||||
shell.openPath(dirPath)
|
shell.openPath(dirPath)
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user