Skip to content

Commit

Permalink
MWPW-156401 fixed #2
Browse files Browse the repository at this point in the history
  • Loading branch information
qiyundai committed Aug 12, 2024
1 parent 721f390 commit f2b59de
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ export function onSubmit(component, props) {
const communityTopicUrl = component.querySelector('#community-url-details').value;
props.payload = { ...props.payload, communityTopicUrl };
} else {
props.payload.delete('communityTopicUrl');
const tempPayload = { ...props.payload };
delete tempPayload.communityTopicUrl;
props.payload = tempPayload;
}
}

Expand Down
6 changes: 2 additions & 4 deletions ecc/blocks/form-handler/data-handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@ export function quickFilter(obj) {

export function setPayloadCache(payload) {
if (!payload) return;
const output = quickFilter(payload);
payloadCache = { ...payloadCache, ...output };
payloadCache = quickFilter(payload);
}

export function getFilteredCachedPayload() {
Expand All @@ -62,8 +61,7 @@ export function getFilteredCachedPayload() {

export function setResponseCache(response) {
if (!response) return;
const output = quickFilter(response);
responseCache = { ...responseCache, ...output };
responseCache = quickFilter(response);
}

export function getFilteredCachedResponse() {
Expand Down

0 comments on commit f2b59de

Please sign in to comment.