// Metro module 859 (f860). import { debug } from "./consoleSandbox"; import { isMatchingPattern } from "./Module832"; import { DEBUG_BUILD } from "./Module823"; const logIgnoredSpan = function logIgnoredSpan(a0) { debug.log(`Ignoring span ${a0.op} - ${a0.description} because it matches \`ignoreSpans\`.`); }; Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" }); export function reparentChildSpans(a0, { parent_span_id, span_id }) { if (parent_span_id) { for (const item of a0) { if (item.parent_span_id === span_id) { item.parent_span_id = parent_span_id; } } } } export function shouldIgnoreSpan(a0, a1) { if (a1?.length && a0.description) { for (const item of a1) { L26: { if (!(typeof item !== "string" && !(item instanceof RegExp))) { if (isMatchingPattern(a0.description, item)) { if (!DEBUG_BUILD) { break L26; } logIgnoredSpan(a0); break L26; } continue; } if (!item.name && !item.op) { continue; } const name = item.name; const r53 = name ? isMatchingPattern(a0.description, item.name) : !name; const op = item.op; const r65 = op ? a0.op && isMatchingPattern(a0.op, item.op) : !op; if (!r53) { continue; } if (!r65) { continue; } if (DEBUG_BUILD) { logIgnoredSpan(a0); } return true; } return true; } return false; } return false; }