refactor: Add lint rules for no unused vars and unused import (#9940)
This commit is contained in:
@@ -79,7 +79,7 @@ export async function handleParseHeaders(req, res, next) {
|
||||
if (Object.prototype.toString.call(context) !== '[object Object]') {
|
||||
throw 'Context is not an object';
|
||||
}
|
||||
} catch (e) {
|
||||
} catch {
|
||||
return malformedContext(req, res);
|
||||
}
|
||||
}
|
||||
@@ -126,7 +126,7 @@ export async function handleParseHeaders(req, res, next) {
|
||||
// to provide x-parse-app-id in header and parse a binary file will fail
|
||||
try {
|
||||
req.body = JSON.parse(req.body);
|
||||
} catch (e) {
|
||||
} catch {
|
||||
return invalidRequest(req, res);
|
||||
}
|
||||
fileViaJSON = true;
|
||||
@@ -173,7 +173,7 @@ export async function handleParseHeaders(req, res, next) {
|
||||
if (Object.prototype.toString.call(info.context) !== '[object Object]') {
|
||||
throw 'Context is not an object';
|
||||
}
|
||||
} catch (e) {
|
||||
} catch {
|
||||
return malformedContext(req, res);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user