This commit is contained in:
janisslsm committed 2026-11-01 12:12:55 +02:00
1 parent 1781d25a15
commit 732c0ad767
33051 files changed
+2591613 -3019689

No files matched your search

+185
View File
@@ -0,0 +1,185 @@
// Metro module 1173 (f1174).
import { debug } from "./Module817";
import { NATIVE } from "./Module1001";
function $mk117651($env) {
return function(a0) {
a0($env[0]);
};
}
let c976_3;
let c976_2 = (this ? this.__awaiter : this) || function(c12878_0, c12878_1, a2, c12878_3) {
let r2 = a2;
let Promise2 = a2;
if (!a2) {
Promise2 = Promise;
r2 = Promise2;
}
return new r2(function(a0, c24273_1) {
let rejected2, step2;
let c24273_0 = a0;
const fulfilled2 = function fulfilled(a0) {
try {
step2(c12878_3.next(a0));
} catch ($e) {
c24273_1($e);
}
};
rejected2 = function rejected(a0) {
try {
step2(c12878_3.throw(a0));
} catch ($e) {
c24273_1($e);
}
};
step2 = function step(a0) {
if (a0.done) {
c24273_0(a0.value);
} else {
let env28849;
let value = a0.value;
const r10 = env28849 = {};
env28849[0] = value;
if (!(value instanceof Promise2)) {
value = new Promise2($mk117651(r10));
}
value.then(fulfilled2, rejected2);
}
};
const r16 = c12878_3.apply(c12878_0, c12878_1 || []);
c12878_3 = r16;
const r18 = r16.next();
const { done, value } = r18;
if (done) {
a0(value);
} else {
let env24274;
const r21 = env24274 = {};
env24274[0] = value;
(value instanceof Promise2 ? value : new Promise2($mk117651(r21))).then(fulfilled2, rejected2);
}
});
};
c976_3 = void 0;
export const logEnricherIntegration = () => ({
name: "LogEnricher",
setup: (a0) => {
let c24275_0 = a0;
a0.on("afterInit", () => {
let c28850_0, c28850_1, c28850_2, c28850_3, c28850_4, c28850_5;
c976_2(void 0, void 0, void 0, function*() {
let r128, r149;
let c31885_2;
let c31885_3 = 0;
let c32096_0, c32096_1;
let r10 = "[LOGS]: Failed to prepare attributes from Native Layer: ";
try {
c32096_0 = void 0;
c31885_3 = 1;
const r48 = yield NATIVE.fetchNativeLogAttributes();
r10 = "[LOGS]: Failed to prepare attributes from Native Layer: ";
c32096_0 = r48;
const r20 = Object;
const r22 = Object;
const r24 = Object;
const r64 = c32096_0 == null ? void 0 : c32096_0.contexts;
c28850_0 = r64;
let r18 = r64 !== null ? r64 !== void 0 ? r64.device : void 0 : void 0;
if (r18) {
const device = c32096_0.contexts.device;
c28850_1 = device;
const brand = device !== null ? c28850_1 !== void 0 ? c28850_1.brand : void 0 : void 0;
const device2 = c32096_0.contexts.device;
c28850_2 = device2;
const model = device2 !== null ? c28850_2 !== void 0 ? c28850_2.model : void 0 : void 0;
const device3 = c32096_0.contexts.device;
c28850_3 = device3;
r18 = {
brand,
model,
family: device3 !== null ? c28850_3 !== void 0 ? c28850_3.family : void 0 : void 0
};
}
const r70 = r24.assign({}, r18);
const r73 = c32096_0 == null ? void 0 : c32096_0.contexts;
c28850_4 = r73;
const r105 = r22.assign(r70, (r73 !== null ? r73 !== void 0 ? r73.os : void 0 : void 0) && {
os: c32096_0.contexts.os.name,
version: c32096_0.contexts.os.version
});
const r108 = c32096_0 == null ? void 0 : c32096_0.contexts;
c28850_5 = r108;
c976_3 = r20.assign(r105, (r108 !== null ? r108 !== void 0 ? r108.release : void 0 : void 0) && {
release: c32096_0.contexts.release
});
c31885_3 = 0;
r128 = Promise.resolve();
} catch ($e) {
const r34 = $e;
let r7 = r34;
c31885_2 = r34;
if (c31885_3 !== 0) {
while (true) {
try {
const r141 = c31885_2;
c31885_3 = 0;
c32096_1 = r141;
r149 = Promise.reject(HermesInternal.concat.call(r10, c32096_1));
} catch (r138) {
r7 = r138;
c31885_2 = r138;
if (c31885_3 === 0) {
break;
}
continue;
}
return r149;
}
}
throw r7;
}
return r128;
}).then(() => {
c24275_0.on("beforeCaptureLog", (a0) => {
if (c976_3 !== void 0) {
let attributes = a0.attributes;
if (!(attributes !== null && attributes !== void 0)) {
attributes = {};
}
const brand = c976_3.brand;
if (!(brand ? attributes["device.brand"] && false : !brand)) {
attributes["device.brand"] = brand;
}
const model = c976_3.model;
if (!(model ? attributes["device.model"] && false : !model)) {
attributes["device.model"] = model;
}
const family = c976_3.family;
if (!(family ? attributes["device.family"] && false : !family)) {
attributes["device.family"] = family;
}
const os = c976_3.os;
if (!(os ? attributes["os.name"] && false : !os)) {
attributes["os.name"] = os;
}
const version = c976_3.version;
if (!(version ? attributes["os.version"] && false : !version)) {
attributes["os.version"] = version;
}
const release = c976_3.release;
if (!(release ? attributes["sentry.release"] && false : !release)) {
attributes["sentry.release"] = release;
}
const integrationByName = c24275_0.getIntegrationByName("MobileReplay");
const r37 = integrationByName == null ? void 0 : integrationByName.getReplayId();
if (!(r37 ? attributes["sentry.replay_id"] && false : !r37)) {
attributes["sentry.replay_id"] = r37;
}
a0.attributes = attributes;
}
});
}, (a0) => {
debug.log(a0);
});
});
}
});