mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-05-29 00:50:22 +09:00
fix: #188
This commit is contained in:
parent
c8b7378b70
commit
8691e95f12
@ -519,6 +519,7 @@ export function ImagePreviewer(props: {
|
|||||||
const updatedContent = markdownContent.replace(
|
const updatedContent = markdownContent.replace(
|
||||||
/!\[.*?\]\((.*?)\)/g,
|
/!\[.*?\]\((.*?)\)/g,
|
||||||
(match, url) => {
|
(match, url) => {
|
||||||
|
if (!url.startsWith("http")) return ``;
|
||||||
const updatedURL = `/api/cors?url=${encodeURIComponent(url)}`;
|
const updatedURL = `/api/cors?url=${encodeURIComponent(url)}`;
|
||||||
return ``;
|
return ``;
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user