Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] deploy에서 캔디 추가 안 됨 #149

Open
LeeJE20 opened this issue Jun 23, 2022 · 0 comments
Open

[BUG] deploy에서 캔디 추가 안 됨 #149

LeeJE20 opened this issue Jun 23, 2022 · 0 comments
Labels
bug Something isn't working

Comments

@LeeJE20
Copy link
Member

LeeJE20 commented Jun 23, 2022

POST {{baseUrl}}/api/candies

로컬에서는 됨

리퀘스트

{
    "category_id": "622930547b0677c52da107b6",
    "candy_name": "testCandy",
    "shopping_link": "https://www.11st.co.kr/products/1236879639",
    "category_image_url": "",
    "detail_info": ""
}

ec2에서 ~/.pm2/logs 에서 cat dist-out.log 확인해보면

SyntaxError: Unexpected token   in JSON at position 3
    at JSON.parse (<anonymous>)
    at Config.loadFromPath (/var/www/html/HandyCandy_Server/node_modules/aws-sdk/lib/config.js:483:24)
    at Function.<anonymous> (/var/www/html/HandyCandy_Server/dist/services/CandiesService.js:229:28)
    at Generator.next (<anonymous>)
    at /var/www/html/HandyCandy_Server/dist/services/CandiesService.js:31:71
    at new Promise (<anonymous>)
    at __awaiter (/var/www/html/HandyCandy_Server/dist/services/CandiesService.js:27:12)
    at Function.addCandy (/var/www/html/HandyCandy_Server/dist/services/CandiesService.js:224:16)
    at /var/www/html/HandyCandy_Server/dist/controllers/candies.js:46:52
    at Generator.next (<anonymous>)
    at /var/www/html/HandyCandy_Server/dist/controllers/candies.js:8:71
    at new Promise (<anonymous>)
    at __awaiter (/var/www/html/HandyCandy_Server/dist/controllers/candies.js:4:12)
    at addCandy (/var/www/html/HandyCandy_Server/dist/controllers/candies.js:37:32)
    at Layer.handle [as handle_request] (/var/www/html/HandyCandy_Server/node_modules/express/lib/router/layer.js:95:5)
    at next (/var/www/html/HandyCandy_Server/node_modules/express/lib/router/route.js:137:13)
@LeeJE20 LeeJE20 added the bug Something isn't working label Jun 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant