Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 uid=33(www-data) gid=33(www-data) groups=33(www-data) Safe-mode: OFF (not secure) /var/www/html/sites/node_modules/@aws-sdk/util-user-agent-node/dist-es/ drwxr-xr-x | |
| Viewing file: Select action/file-type: import { __awaiter, __generator, __read, __spreadArray } from "tslib";
import { loadConfig } from "@aws-sdk/node-config-provider";
import { platform, release } from "os";
import { env, versions } from "process";
import { isCrtAvailable } from "./is-crt-available";
export var UA_APP_ID_ENV_NAME = "AWS_SDK_UA_APP_ID";
export var UA_APP_ID_INI_NAME = "sdk-ua-app-id";
export var defaultUserAgent = function (_a) {
var serviceId = _a.serviceId, clientVersion = _a.clientVersion;
var sections = [
["aws-sdk-js", clientVersion],
["os/".concat(platform()), release()],
["lang/js"],
["md/nodejs", "".concat(versions.node)],
];
var crtAvailable = isCrtAvailable();
if (crtAvailable) {
sections.push(crtAvailable);
}
if (serviceId) {
sections.push(["api/".concat(serviceId), clientVersion]);
}
if (env.AWS_EXECUTION_ENV) {
sections.push(["exec-env/".concat(env.AWS_EXECUTION_ENV)]);
}
var appIdPromise = loadConfig({
environmentVariableSelector: function (env) { return env[UA_APP_ID_ENV_NAME]; },
configFileSelector: function (profile) { return profile[UA_APP_ID_INI_NAME]; },
default: undefined,
})();
var resolvedUserAgent = undefined;
return function () { return __awaiter(void 0, void 0, void 0, function () {
var appId;
return __generator(this, function (_a) {
switch (_a.label) {
case 0:
if (!!resolvedUserAgent) return [3, 2];
return [4, appIdPromise];
case 1:
appId = _a.sent();
resolvedUserAgent = appId ? __spreadArray(__spreadArray([], __read(sections), false), [["app/".concat(appId)]], false) : __spreadArray([], __read(sections), false);
_a.label = 2;
case 2: return [2, resolvedUserAgent];
}
});
}); };
};
|
:: Command execute :: | |
--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0046 ]-- |