Skip to content

Commit 76ca224

Browse files
committed
hotfix: hola revert
1 parent 138c7af commit 76ca224

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

SouP/src/main/java/Matching/SouP/crawler/Hola/HolaService.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public void getHolaPostData(){
3939
log.warn("글 갯수 = {} ",count);
4040
for (int i = count; i > 0; i--) {
4141
if(i==count){
42-
driver.findElement(By.cssSelector("#root > main > ul > a:nth-child(2)")).click();
42+
driver.findElement(By.cssSelector("#root > main > ul > a:nth-child(1)")).click();
4343
String first = driver.getCurrentUrl().substring(beginIndex);
4444
if(first.compareTo(standard) <= 0) {
4545
log.warn("사이트 내 가장 최신글 번호 = {}, 따라서 불러올 글이 없습니다!",first);
@@ -48,7 +48,7 @@ public void getHolaPostData(){
4848
else
4949
driver.navigate().back();
5050
}
51-
int aSelector = i*2; // 짝수번만 사용 예정
51+
int aSelector = i*2 - 1; // 홀수번만 사용 예정
5252
Elements eachPost = element.select("a:nth-child(" + aSelector + ")");
5353
driver.get(urlHola + eachPost.attr("href"));
5454
Thread.sleep(500);

0 commit comments

Comments
 (0)