Skip to content

Commit befd117

Browse files
committed
Prompt to save before closing tab of new file
1 parent 954f9cf commit befd117

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ui/arduino/store.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,7 @@ async function store(state, emitter) {
369369
emitter.on('close-tab', (id) => {
370370
log('close-tab', id)
371371
const currentTab = state.openFiles.find(f => f.id === id)
372-
if (currentTab.hasChanges && currentTab.parentFolder !== null) {
372+
if (currentTab.hasChanges) {
373373
let response = confirm("Your file has unsaved changes. Are you sure you want to proceed?")
374374
if (!response) return false
375375
}

0 commit comments

Comments
 (0)