Skip to content

Conversation

@Atipico1
Copy link

@Atipico1 Atipico1 commented May 2, 2024

💎 과제 구현 설명

과제를 위해 사용했던 함수, 수정한 파일 등 구현 내용에 대한 간단한 설명을 작성해 주세요.

🏁 PR 체크리스트

  • 코드가 오류 없이 정상적으로 실행되나요?
  • 커밋 메시지 컨벤션(템플릿 활용)을 준수했나요?
  • 과제 마감기한을 준수했나요?

🖼️ Screenshot / Video

🙌 Issue

과제 수행 중 어려웠던 부분이나 궁금했던 점을 자유롭게 작성해 주세요.

Copy link
Contributor

@isuh88 isuh88 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

수고했슴당~~ 👍

Comment on lines 46 to 65
const vote = async (val) => {
try {
// ### TO DO ###
// #############
const response = await axios.post(
"https://api.thecatapi.com/v1/votes",
{
image_id: image.id,
sub_id: userId,
value: val,
},
{
headers: {
"Content-Type": "application/json",
"x-api-key":
"live_Iyhi1ILrF0FD1vlsdHpX4CYBM37yG1ZXsUjP58Jx4Wov7qsp27cZmsuBjMt0HYVo",
},
}
);
} catch (err) {
console.log(err);
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

앗 아까 쓰는걸 깜박했는데, 지금은 투표 후에 요청은 post로 잘 전송되나 새로운 고양이 이미지가 다시 불러와지지는 않아요! getImage()를 통해 vote를 호출하여 투표를 완료하면 다음 고양이 사진이 보이도록 수정하면 좋을 것 같네요 :)

Copy link

@charijyard charijyard left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

제가 아이디를 안 알려드려서 assignee가 잘못 지정된 것 같아요 ㅎㅎ 저(박민서)의 아이디는 charijyard입니다 🙂! 그리고 코드도 저한테는 완벽해 보이네요 ~~~ 고생하셨습니다앙

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants