Skip to content

Commit de34365

Browse files
Dean OhashiDean Ohashi
authored andcommitted
fixed bug to allow multiple saves in single session
1 parent 60447ab commit de34365

File tree

1 file changed

+0
-29
lines changed

1 file changed

+0
-29
lines changed

src/components/SaveProjectComponent.vue

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -51,36 +51,7 @@ export default {
5151
});
5252
},
5353
saveProjectJSON() {
54-
let projectLocation = this.$store.state.projects[
55-
this.$store.state.activeTab
56-
].lastSavedLocation;
57-
if (projectLocation) {
58-
console.log('IN SAVE LOCATION', this.$store.state);
59-
let state = this.$store.state;
60-
let routes = state.routes;
61-
for (let view in routes) {
62-
routes[view].forEach(component => {
63-
let htmlList = component.htmlList;
64-
this.parseAndDelete(htmlList);
65-
});
66-
}
67-
let componentMap = this.$store.state.componentMap;
68-
console.log('compmap', componentMap);
69-
for (let component in componentMap) {
70-
if (componentMap[component].htmlList) {
71-
let comphtml = componentMap[component].htmlList;
72-
console.log('COMPHTML', comphtml);
73-
this.parseAndDelete(comphtml);
74-
}
75-
}
76-
77-
fs.writeFileSync(projectLocation, JSON.stringify(state));
78-
79-
console.log('PROJECT SAVED TO LAST SAVED LOCATION');
80-
} else {
81-
// ipc.send('show-save-json-dialog');
8254
this.showSaveJSONDialog();
83-
}
8455
},
8556
saveJSONLocation(data){
8657
//delete original key from local forage

0 commit comments

Comments
 (0)