Merge pull request #3495 from overleaf/ae-prettier-2

Upgrade Prettier to v2

GitOrigin-RevId: 85aa3fa1acb6332c4f58c46165a43d1a51471f33
This commit is contained in:
Alf Eaton
2021-04-14 14:17:21 +01:00
committed by Copybot
parent 930d7ba028
commit 1ebc8a79cb
582 changed files with 20382 additions and 20374 deletions
@@ -23,7 +23,7 @@ module.exports = ProxyManager = {
for (var proxyUrl in settings.proxyUrls) {
const target = settings.proxyUrls[proxyUrl]
result.push(
(function(target) {
(function (target) {
const method =
(target.options != null ? target.options.method : undefined) ||
'get'
@@ -39,7 +39,7 @@ module.exports = ProxyManager = {
},
createProxy(target) {
return function(req, res, next) {
return function (req, res, next) {
const targetUrl = makeTargetUrl(target, req)
logger.log({ targetUrl, reqUrl: req.url }, 'proxying url')
@@ -67,7 +67,7 @@ module.exports = ProxyManager = {
// make a URL from a proxy target.
// if the query is specified, set/replace the target's query with the given query
var makeTargetUrl = function(target, req) {
var makeTargetUrl = function (target, req) {
const targetUrl = URL.parse(parseSettingUrl(target, req))
if (req.query != null && Object.keys(req.query).length > 0) {
targetUrl.query = req.query
@@ -76,7 +76,7 @@ var makeTargetUrl = function(target, req) {
return targetUrl.format()
}
var parseSettingUrl = function(target, { params }) {
var parseSettingUrl = function (target, { params }) {
let path
if (typeof target === 'string') {
return target