diff --git a/src/core/drive/navigator.js b/src/core/drive/navigator.js index 8b0d67947..c4f9cb1f1 100644 --- a/src/core/drive/navigator.js +++ b/src/core/drive/navigator.js @@ -168,7 +168,13 @@ export class Navigator { } #sanitizeVisitOptionsForTransfer(options) { - const { initiator, referrer, visitCachedSnapshot, ...rest } = options - return window.structuredClone(rest) + return Object.entries(options).reduce((sanitized, [key, value]) => { + try { + sanitized[key] = window.structuredClone(value) + } catch (_) { + // Ignore non-transferable values + } + return sanitized + }, {}) } }