@google-cloud/compute
Advanced tools
Comparing version 4.3.0 to 4.4.0
@@ -78,3 +78,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -94,4 +94,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -101,3 +104,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -108,5 +111,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -137,3 +140,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -218,3 +221,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -231,3 +234,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,0 +237,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -227,3 +230,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,3 +243,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -243,0 +246,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -233,3 +236,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -246,3 +249,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -249,0 +252,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -215,3 +218,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -228,3 +231,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -231,0 +234,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -234,3 +237,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -247,3 +250,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -250,0 +253,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -233,3 +236,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -246,3 +249,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -249,0 +252,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -216,3 +219,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -229,3 +232,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -232,0 +235,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -208,3 +211,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -221,3 +224,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -224,0 +227,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -226,3 +229,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,3 +242,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -242,0 +245,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -226,3 +229,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,3 +242,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -242,0 +245,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -215,3 +218,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -228,3 +231,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -231,0 +234,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -216,3 +219,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -229,3 +232,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -232,0 +235,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -208,3 +211,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -221,3 +224,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -224,0 +227,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -215,3 +218,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -228,3 +231,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -231,0 +234,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -227,3 +230,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,3 +243,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -243,0 +246,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -232,3 +235,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -245,3 +248,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -248,0 +251,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -227,3 +230,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,3 +243,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -243,0 +246,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -231,3 +234,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -244,3 +247,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -247,0 +250,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -215,3 +218,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -228,3 +231,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -231,0 +234,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -230,3 +233,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -243,3 +246,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -246,0 +249,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -229,3 +232,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -242,3 +245,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -245,0 +248,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -214,3 +217,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -227,3 +230,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -230,0 +233,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -232,3 +235,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -245,3 +248,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -248,0 +251,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -220,3 +223,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -233,3 +236,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,0 +239,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -220,3 +223,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -233,3 +236,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,0 +239,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -208,3 +211,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -221,3 +224,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -224,0 +227,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -234,3 +237,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -247,3 +250,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -250,0 +253,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -214,3 +217,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -227,3 +230,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -230,0 +233,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -220,3 +223,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -233,3 +236,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,0 +239,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -220,3 +223,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -233,3 +236,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,0 +239,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -214,3 +217,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -227,3 +230,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -230,0 +233,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -214,3 +217,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -227,3 +230,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -230,0 +233,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -226,3 +229,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,3 +242,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -242,0 +245,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -228,3 +231,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,3 +244,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -244,0 +247,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -214,3 +217,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -227,3 +230,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -230,0 +233,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -228,3 +231,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,3 +244,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -244,0 +247,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -92,4 +92,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -99,3 +102,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -106,5 +109,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -135,3 +138,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -209,3 +212,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -222,3 +225,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -225,0 +228,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -221,3 +224,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,3 +237,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,0 +240,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -229,3 +232,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -242,3 +245,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -245,0 +248,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -220,3 +223,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -233,3 +236,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,0 +239,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -227,3 +230,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,3 +243,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -243,0 +246,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -228,3 +231,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,3 +244,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -244,0 +247,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -223,3 +226,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -236,3 +239,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -239,0 +242,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -225,3 +228,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,3 +241,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -241,0 +244,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -224,3 +227,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -237,3 +240,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -240,0 +243,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -222,3 +225,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -235,3 +238,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -238,0 +241,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -214,3 +217,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -227,3 +230,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -230,0 +233,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -214,3 +217,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -227,3 +230,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -230,0 +233,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -78,3 +78,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -94,4 +94,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -101,3 +104,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -108,5 +111,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -137,3 +140,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -218,3 +221,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -231,3 +234,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -234,0 +237,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -75,3 +75,3 @@ "use strict"; | ||
constructor(opts, gaxInstance) { | ||
var _a, _b, _c, _d, _e; | ||
var _a, _b, _c, _d, _e, _f; | ||
this._terminated = false; | ||
@@ -91,4 +91,7 @@ this.descriptors = { | ||
} | ||
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object' | ||
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN'] | ||
: undefined; | ||
this._universeDomain = | ||
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com'; | ||
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com'; | ||
this._servicePath = 'compute.' + this._universeDomain; | ||
@@ -98,3 +101,3 @@ const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath; | ||
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port; | ||
const clientConfig = (_c = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _c !== void 0 ? _c : {}; | ||
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {}; | ||
// Implicitly enable HTTP transport for the APIs that use REST as transport (e.g. Google Cloud Compute). | ||
@@ -105,5 +108,5 @@ if (!opts) { | ||
else { | ||
opts.fallback = (_d = opts.fallback) !== null && _d !== void 0 ? _d : true; | ||
opts.fallback = (_e = opts.fallback) !== null && _e !== void 0 ? _e : true; | ||
} | ||
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
const fallback = (_f = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _f !== void 0 ? _f : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function'); | ||
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts); | ||
@@ -134,3 +137,3 @@ // If scopes are unset in options and we're connecting to a non-default endpoint, set scopes just in case. | ||
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`]; | ||
if (typeof process !== 'undefined' && 'versions' in process) { | ||
if (typeof process === 'object' && 'versions' in process) { | ||
clientHeader.push(`gl-node/${process.versions.node}`); | ||
@@ -208,3 +211,3 @@ } | ||
static get servicePath() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -221,3 +224,3 @@ process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning'); | ||
static get apiEndpoint() { | ||
if (typeof process !== undefined && | ||
if (typeof process === 'object' && | ||
typeof process.emitWarning === 'function') { | ||
@@ -224,0 +227,0 @@ process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning'); |
@@ -7,2 +7,9 @@ # Changelog | ||
## [4.4.0](https://github.com/googleapis/google-cloud-node/compare/compute-v4.3.0...compute-v4.4.0) (2024-03-29) | ||
### Features | ||
* [Many APIs] add several fields to manage state of database encryption update ([#5187](https://github.com/googleapis/google-cloud-node/issues/5187)) ([1952fbe](https://github.com/googleapis/google-cloud-node/commit/1952fbe432b96115278d42e5c1dbdbc7de39036b)) | ||
## [4.3.0](https://github.com/googleapis/google-cloud-node/compare/compute-v4.2.0...compute-v4.3.0) (2024-03-07) | ||
@@ -9,0 +16,0 @@ |
{ | ||
"name": "@google-cloud/compute", | ||
"description": "Google Compute Engine Client Library for Node.js", | ||
"version": "4.3.0", | ||
"version": "4.4.0", | ||
"license": "Apache-2.0", | ||
@@ -6,0 +6,0 @@ "author": "Google LLC", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 2 instances in 1 package
63654052
220246
192