Skip to content

Commit

Permalink
fix: query value
Browse files Browse the repository at this point in the history
  • Loading branch information
Kholid060 committed Jan 12, 2024
1 parent b5200ca commit 1332572
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/execute/index.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { parseJSON } from '@/utils/helper';
import { sendMessage } from '@/utils/message';
import Browser from 'webextension-polyfill';

Expand All @@ -11,7 +12,10 @@ function getWorkflowDetail() {
const { 1: workflowId } = pathname.split('/');

searchParams.forEach((key, value) => {
variables[key] = decodeURIComponent(value);
const varValue = parseJSON(decodeURIComponent(value), '##_empty');
if (varValue === '##_empty') return;

variables[key] = varValue;
});

return { workflowId: workflowId ?? '', variables };
Expand Down

0 comments on commit 1332572

Please sign in to comment.