From 348d7cf4e19b80bd382305f7afb64aa6a8174049 Mon Sep 17 00:00:00 2001 From: Kazuaki Matsuo Date: Fri, 9 Apr 2021 10:50:09 +0900 Subject: [PATCH] chore: set appium-inspector as UA to match with master (#1761) --- app/override/override_http.js | 2 +- app/override/override_https.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/override/override_http.js b/app/override/override_http.js index 29ea1e4a6..7c519f77d 100644 --- a/app/override/override_http.js +++ b/app/override/override_http.js @@ -5,7 +5,7 @@ export const overrideHttpUserAgent = () => { originalHttpRequest = http.request; http.request = function (options, callback) { - options.headers['User-Agent'] = `admc/${wdPackageJson.name}/${wdPackageJson.version} ${packageJson.name}/${packageJson.version}`; + options.headers['User-Agent'] = `admc/${wdPackageJson.name}/${wdPackageJson.version} appium-inspector/${packageJson.version}`; return originalHttpRequest(options, function (res) { if (callback) { diff --git a/app/override/override_https.js b/app/override/override_https.js index 9b502a585..1a2045393 100644 --- a/app/override/override_https.js +++ b/app/override/override_https.js @@ -5,7 +5,7 @@ export const overrideHttpsUserAgent = () => { originalHttpsRequest = https.request; https.request = function (options, callback) { - options.headers['User-Agent'] = `admc/${wdPackageJson.name}/${wdPackageJson.version} ${packageJson.name}/${packageJson.version}`; + options.headers['User-Agent'] = `admc/${wdPackageJson.name}/${wdPackageJson.version} appium-inspector/${packageJson.version}`; return originalHttpsRequest(options, function (res) { if (callback) {