mirror of
https://github.com/CringeStudios/element-desktop.git
synced 2025-01-18 23:44:59 +01:00
commit
754634ef31
@ -17,3 +17,9 @@ module.exports = {
|
||||
// don't use babel, so remove it & put the original back
|
||||
delete module.exports.rules["babel/no-invalid-this"];
|
||||
module.exports.rules["no-invalid-this"] = "error";
|
||||
|
||||
// also override the line length to be consistent with
|
||||
// vector-web / react-sdk rather than js-sdk
|
||||
module.exports.rules["max-len"] = ["warn", {
|
||||
code: 120,
|
||||
}];
|
||||
|
@ -301,14 +301,14 @@ ipcMain.on('seshat', async function(ev, payload) {
|
||||
|
||||
const sendError = (id, e) => {
|
||||
const error = {
|
||||
message: e.message
|
||||
}
|
||||
message: e.message,
|
||||
};
|
||||
|
||||
mainWindow.webContents.send('seshatReply', {
|
||||
id:id,
|
||||
error: error
|
||||
id: id,
|
||||
error: error,
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
const args = payload.args || [];
|
||||
let ret;
|
||||
@ -336,17 +336,19 @@ ipcMain.on('seshat', async function(ev, payload) {
|
||||
break;
|
||||
|
||||
case 'deleteEventIndex':
|
||||
const deleteFolderRecursive = async(p) => {
|
||||
for (let entry of await afs.readdir(p)) {
|
||||
{
|
||||
const deleteFolderRecursive = async (p) => {
|
||||
for (const entry of await afs.readdir(p)) {
|
||||
const curPath = path.join(p, entry);
|
||||
await afs.unlink(curPath);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
try {
|
||||
await deleteFolderRecursive(eventStorePath);
|
||||
} catch (e) {
|
||||
}
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
|
@ -38,7 +38,6 @@ module.exports.start = function startAutoUpdate(updateBaseUrl) {
|
||||
// and also acts as a convenient cache-buster to ensure that when the
|
||||
// app updates it always gets a fresh value to avoid update-looping.
|
||||
url = `${updateBaseUrl}macos/?localVersion=${encodeURIComponent(app.getVersion())}`;
|
||||
|
||||
} else if (process.platform === 'win32') {
|
||||
url = `${updateBaseUrl}win32/${process.arch}/`;
|
||||
} else {
|
||||
@ -64,7 +63,7 @@ module.exports.start = function startAutoUpdate(updateBaseUrl) {
|
||||
// will fail if running in debug mode
|
||||
console.log('Couldn\'t enable update checking', err);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
ipcMain.on('install_update', installUpdate);
|
||||
ipcMain.on('check_updates', pollForUpdates);
|
||||
|
Loading…
Reference in New Issue
Block a user