Bug 1576768 - Automatically format .sjs files using prettier. r=Standard8,agi,zombie,extension-reviewers

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D128482
This commit is contained in:
Evgenia Kotovich
2021-10-18 09:26:33 +00:00
parent 4ceebe1232
commit 685e68c48b
421 changed files with 7235 additions and 4987 deletions

View File

@@ -1,5 +1,9 @@
const CC = Components.Constructor;
const BinaryInputStream = CC("@mozilla.org/binaryinputstream;1", "nsIBinaryInputStream", "setInputStream");
const BinaryInputStream = CC(
"@mozilla.org/binaryinputstream;1",
"nsIBinaryInputStream",
"setInputStream"
);
// Returns a JSON string containing the query string arguments and the
// request body parsed as JSON.
@@ -20,7 +24,7 @@ function handleRequest(request, response) {
const body = String.fromCharCode.apply(null, bytes);
// Write response body
const data = {queryString: {}, body: body ? JSON.parse(body) : {}};
const data = { queryString: {}, body: body ? JSON.parse(body) : {} };
const params = request.queryString.split("&");
for (const param of params) {
const [key, value] = param.split("=");