From 8eaa0c33387ff188357fad7d964bb59156723284 Mon Sep 17 00:00:00 2001 From: Eric Dauenhauer Date: Thu, 1 Feb 2024 15:50:00 -0600 Subject: [PATCH] Fix Verify step --- lib/ui/public/app/store.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/ui/public/app/store.js b/lib/ui/public/app/store.js index a796ffc..02088ac 100644 --- a/lib/ui/public/app/store.js +++ b/lib/ui/public/app/store.js @@ -3,6 +3,7 @@ import fieldData from './fieldData'; import v4Fields from './v4fields'; import axios from 'axios'; import { get } from 'lodash'; +import { toRaw } from 'vue'; const initStore = (config, ui) => createStore({ state: { @@ -132,8 +133,10 @@ const initStore = (config, ui) => createStore({ await context.dispatch('createFilter', filterConfig); } context.state.filters.forEach(filter => { - flow.steps.push(filter); - }); + // the flow gets passed back to the app via a window.postMessage call, which clones objects passed in the message. + // As of Vuex 4, state items are Proxy objects, which cannot be cloned, so we have to use `toRaw()`. + flow.steps.push(toRaw(filter)); + }); } context.state.ui.create({ flow }); }