Skip to content

Commit 8654656

Browse files
committed
Revert
1 parent bb1fe92 commit 8654656

File tree

1 file changed

+7
-21
lines changed

1 file changed

+7
-21
lines changed

src/settings/appSettings.js

Lines changed: 7 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ import fsOperation from "fileSystem";
66
import actions from "handlers/quickTools";
77
import actionStack from "lib/actionStack";
88
import constants from "lib/constants";
9-
import EditorFile from "lib/editorFile";
109
import lang from "lib/lang";
1110
import openFile from "lib/openFile";
1211
import appSettings from "lib/settings";
@@ -158,7 +157,7 @@ export default function otherSettings() {
158157
{
159158
key: "excludeFolders",
160159
text: strings["exclude files"],
161-
/*value: values.excludeFolders.join("\n"),
160+
value: values.excludeFolders.join("\n"),
162161
prompt: strings["exclude files"],
163162
promptType: "textarea",
164163
promptOptions: {
@@ -167,7 +166,7 @@ export default function otherSettings() {
167166
return item.trim().length > 0;
168167
});
169168
},
170-
},*/
169+
},
171170
},
172171
{
173172
key: "defaultFileEncoding",
@@ -262,24 +261,11 @@ export default function otherSettings() {
262261
break;
263262

264263
case "excludeFolders":
265-
actionStack.pop(actionStack.length);
266-
const editor = new EditorFile(strings["exclude files"], {
267-
text: values.excludeFolders.join("\n"),
268-
});
269-
editor.onsave = function (event) {
270-
event.preventDefault();
271-
const data = editor.session.getValue();
272-
273-
appSettings.update({
274-
[key]: data
275-
.split("\n")
276-
.map((item) => item.trim())
277-
.filter((item) => item.length > 0),
278-
});
279-
280-
editor.isUnsaved = false;
281-
};
282-
return;
264+
value = value
265+
.split("\n")
266+
.map((item) => item.trim())
267+
.filter((item) => item.length > 0);
268+
break;
283269

284270
default:
285271
break;

0 commit comments

Comments
 (0)