Endpoint call using heroku

70 views Asked by At

I have deployed my backend on heroku,

https://morning-tor-91556.herokuapp.com/

when go to this link its working fine but now I want to call my endpoint /skills which is I have made in nodeJS in my backend the code is

app.get("/skills",function(req,res){
    Skill.find(function(err,foundSkills){
      if(!err){
        res.send(foundSkills);
        console.log(foundSkills);
      }else{
        res.send(err);
      }
    });
  });

https://morning-tor-91556.herokuapp.com/skills

but when I go to this link its just loading rather then the response which I should get from get request but if I go to localhost:9000/skills I got my collection as I required.

so any idea what can I do.

1

There are 1 answers

2
salodore On

The error is probably in the database configuration, you should share the full code regarding it.