X Tutup
Commit aaa17816 authored by Cosmo Myzrail Gorynych's avatar Cosmo Myzrail Gorynych 😼
Browse files

🐛 Fix ct.js saving projects' scripts with CRLF sequence instead of LF,...

🐛 Fix ct.js saving projects' scripts with CRLF sequence instead of LF, which caused them to be one-lined in the .ict file, making merging changes harder for Git users. You can fix the existing scripts by cutting and pasting their contents back.
parent 0c4194be
Loading
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -8,10 +8,12 @@ export const dropScriptModel = (script: Script) => {
};
/** This method is to be used when loading a project or creating a new script */
export const addScriptModel = (script: Script) => {
    scriptModels.set(script, monaco.editor.createModel(
    const model = monaco.editor.createModel(
        script.code,
        'typescript'
    ));
    );
    model.setEOL(monaco.editor.EndOfLineSequence.LF);
    scriptModels.set(script, model);
};
/** Resets the monaco file models and loads in all the script */
export const loadScriptModels = (project: IProject) => {
X Tutup