Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../httpdocs/wp-conte.../plugins/leadin/scripts/feedback
File: feedbackFormApi.ts
import $ from 'jquery';
[0] Fix | Delete
[1] Fix | Delete
const portalId = '6275621';
[2] Fix | Delete
const formId = '0e8807f8-2ac3-4664-b742-44552bfa09e2';
[3] Fix | Delete
const formSubmissionUrl = `https://api.hsforms.com/submissions/v3/integration/submit/${portalId}/${formId}`;
[4] Fix | Delete
[5] Fix | Delete
export function submitFeedbackForm(formSelector: string) {
[6] Fix | Delete
const formSubmissionPayload = {
[7] Fix | Delete
fields: $(formSelector).serializeArray(),
[8] Fix | Delete
skipValidation: true,
[9] Fix | Delete
};
[10] Fix | Delete
[11] Fix | Delete
return new Promise((resolve, reject) => {
[12] Fix | Delete
$.ajax({
[13] Fix | Delete
type: 'POST',
[14] Fix | Delete
url: formSubmissionUrl,
[15] Fix | Delete
contentType: 'application/json',
[16] Fix | Delete
data: JSON.stringify(formSubmissionPayload),
[17] Fix | Delete
success: resolve,
[18] Fix | Delete
error: reject,
[19] Fix | Delete
});
[20] Fix | Delete
});
[21] Fix | Delete
}
[22] Fix | Delete
[23] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function