stripping ChatGPT in front of the response. Fixes #60

This commit is contained in:
Mic 2024-05-15 19:22:45 +02:00
parent 9b7f46c8b0
commit 86d8c5044a

View file

@ -97,6 +97,7 @@ async function chatgpt_getFromDOM(pos) {
response = responseDivs[nthOfResponse - 1].textContent;
}
response = response.replace(/^ChatGPTChatGPT/, ''); // strip sender name
response = response.replace(/^ChatGPT/, ''); // strip sender name
response = response.trim().replace(/^"|"$/g, ''); // strip quotation marks
//console.log('chatgpt_getFromDOM: ' + response);
}