Skip to content

armgit / rea

Public Imported from GitHub
0

Reverse engineer anything with agents, from app behavior down to native binaries.

fix(browser): carry unknown XML ancestry through metadata contracts

morlutoe8d22ec9eb63
diff --git a/src/browser/CdpCaptureDocuments.test.ts b/src/browser/CdpCaptureDocuments.test.ts
index 362951605..fe67f90aa 100644
--- a/src/browser/CdpCaptureDocuments.test.ts
+++ b/src/browser/CdpCaptureDocuments.test.ts
@@ -139,7 +139,19 @@ describe("CDP DOM string and namespace validity", () => {
{ field: "attributeValue", index: 20 },
] as const)(
"omits a node when its $field string index is invalid ($index)",
- ({ field, index, malformedString }) => {
+ ({
+ field,
+ index,
+ malformedString,
+ }: {
+ readonly field:
+ | "nodeName"
+ | "nodeValue"
+ | "attributeName"
+ | "attributeValue";
+ readonly index: number;
+ readonly malformedString?: boolean;
+ }) => {
const strings: unknown[] = [
origin + "/app",
"#document",
diff --git a/src/browser/CdpCaptureDocuments.ts b/src/browser/CdpCaptureDocuments.ts
index da7eb8019..8aeee7e9a 100644
--- a/src/browser/CdpCaptureDocuments.ts
+++ b/src/browser/CdpCaptureDocuments.ts
@@ -561,7 +561,7 @@ interface DomMetadataOptions {
readonly nodeName: string;
readonly allowedOrigins: ReadonlySet<string>;
readonly svgElement: boolean;
- readonly xmlDocument: boolean;
+ readonly xmlDocument: boolean | undefined;
readonly xlinkHref: string | undefined;
}