Skip to content

Commit

Permalink
[fix] 세부 정보 앞뒤 공백 및 줄바꿈 제거 (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
youngniw committed May 16, 2022
1 parent e45d1e0 commit d5ae801
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,10 @@ public Medicine getMedicineInfo(Document document) { // 지식백과에서의

if (textElement != null) {
String text = textElement.html()
.replace("<br>", "\n") // 줄바꿈 모두 저장
.replace("<br>", "\n") // 줄바꿈 모두 저장
.replaceAll("\\[허가사항변경[^]]*]\n*", "") // [허가사항변경] 관련 불필요 내용 제거
.replaceAll("<[^>]*>", ""); // 태그 모두 제거
.replaceAll("<[^>]*>", "") // 태그 모두 제거
.strip();

switch (topic) {
case "외형정보":
Expand Down

0 comments on commit d5ae801

Please sign in to comment.