aboutsummaryrefslogtreecommitdiff
path: root/scripts/patcher/common.js
diff options
context:
space:
mode:
authorVen <vendicated@riseup.net>2022-10-06 00:42:58 +0200
committerGitHub <noreply@github.com>2022-10-06 00:42:58 +0200
commit74c3930e0a5ed264f330bc32c27116ead1063c5d (patch)
treea29ba43787c8cf8bbee648b5b478a8152086f965 /scripts/patcher/common.js
parente563521416052808bcec57057b921f0c0b6ca594 (diff)
downloadVencord-74c3930e0a5ed264f330bc32c27116ead1063c5d.tar.gz
Vencord-74c3930e0a5ed264f330bc32c27116ead1063c5d.tar.bz2
Vencord-74c3930e0a5ed264f330bc32c27116ead1063c5d.zip
add eslint config (#53)
* eslint * workflow * lint main
Diffstat (limited to 'scripts/patcher/common.js')
-rw-r--r--scripts/patcher/common.js24
1 files changed, 12 insertions, 12 deletions
diff --git a/scripts/patcher/common.js b/scripts/patcher/common.js
index 94cb383..f750601 100644
--- a/scripts/patcher/common.js
+++ b/scripts/patcher/common.js
@@ -63,8 +63,8 @@ function question(question) {
terminal: false,
});
- return new Promise((resolve) => {
- rl.question(question, (answer) => {
+ return new Promise(resolve => {
+ rl.question(question, answer => {
rl.close();
resolve(answer);
});
@@ -72,7 +72,7 @@ function question(question) {
}
async function getMenuItem(installations) {
- let menuItems = installations.map((info) => ({
+ let menuItems = installations.map(info => ({
title: info.patched ? "[MODIFIED] " + info.location : info.location,
info,
}));
@@ -122,9 +122,9 @@ function getWindowsDirs() {
const appDirs = fs
.readdirSync(location, { withFileTypes: true })
- .filter((file) => file.isDirectory())
- .filter((file) => file.name.startsWith("app-"))
- .map((file) => path.join(location, file.name));
+ .filter(file => file.isDirectory())
+ .filter(file => file.name.startsWith("app-"))
+ .map(file => path.join(location, file.name));
let versions = [];
let patched = false;
@@ -169,9 +169,9 @@ function getDarwinDirs() {
const appDirs = fs
.readdirSync(location, { withFileTypes: true })
- .filter((file) => file.isDirectory())
- .filter((file) => file.name.startsWith("Resources"))
- .map((file) => path.join(location, file.name));
+ .filter(file => file.isDirectory())
+ .filter(file => file.name.startsWith("Resources"))
+ .map(file => path.join(location, file.name));
let versions = [];
let patched = false;
@@ -239,13 +239,13 @@ function getLinuxDirs() {
} else {
appDirs = fs
.readdirSync(location, { withFileTypes: true })
- .filter((file) => file.isDirectory())
+ .filter(file => file.isDirectory())
.filter(
- (file) =>
+ file =>
file.name.startsWith("app-") ||
file.name === "resources"
)
- .map((file) => path.join(location, file.name));
+ .map(file => path.join(location, file.name));
}
let versions = [];