moveing files

This commit is contained in:
antelle 2019-01-07 18:35:29 +01:00
parent f3c4af1cbb
commit 090e75b6ed
1 changed files with 2 additions and 2 deletions

View File

@ -408,9 +408,9 @@ function restorePreferences() {
const oldProfilePath = path.join(tempUserDataPath, oldProfile.dir);
const newProfilePath = path.join(tempUserDataPath, newProfile.dir);
if (fs.existsSync(path.join(oldProfilePath, 'Cookies'))) {
const oldCookies = fs.readFileSync(path.join(oldProfilePath, 'Cookies'));
fs.mkdirSync(newProfilePath);
fs.writeFileSync(path.join(newProfilePath, 'Cookies'), oldCookies);
fs.renameSync(path.join(oldProfilePath, 'Cookies'),
path.join(newProfilePath, 'Cookies'));
}
}
}