Skip to content

Commit

Permalink
Merge pull request #87 from GPGT-Algorithm-Study/dev
Browse files Browse the repository at this point in the history
fix: 이미지 업로드 시 정규표현식 수정
  • Loading branch information
klloo authored Feb 8, 2024
2 parents 8d958ef + ff62d11 commit 5eff5ab
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/pages/Board/Write/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,9 @@ function Write({ mode, type, closeWriteMode, post }) {

// 컨텐츠에서 이미지 uuid만 파싱
const getImageUuids = useCallback((markdownContent) => {
const regex = /!\[\]\((.*?)\)/g;
const regex = /!\[.*?\]\((.*?)\)/g;
const uuids = [];
console.log(markdownContent);
let match;
while ((match = regex.exec(markdownContent)) !== null) {
const uuid = match[1].split('/').splice(-1)[0];
Expand Down

0 comments on commit 5eff5ab

Please sign in to comment.