title: How to fix 'Parsing error: Unexpected token' in Node?
body: <p>On saving the code (Node JS), getting the error, 'Parsing error: Unexpected Token'
  Note - Mongo connected</p>
  
  <p>Tried adjusting the curly brackets and semicolon, still not working
  What am I doing wrong?
  Below is the code,</p>
  
  <pre><code>var express = require("express");
  var app = express();
  var bodyParser = require("body-parser");
  var mongoose = require("mongoose");
  
  //connecting and creating a database
  mongoose.connect("mongodb://localhost/yelp_camp");
  
  app.use(bodyParser.urlencoded({extended: true}));
  
  app.set("view engine", "ejs");
  
  //schema setup
  var campgroundSchema = new mongoose.Schema({
      name: String,
      url: String
  });
  
  var Campground = mongoose.model("Campground", campgroundSchema);
  Campground.create( {name: "CampAliBaba", image:"https://photosforclass.com/download/flickr-7121865553"},
                      function(err, campground){
                          if (err){
                              console.log(err);
                      }
                      else {
                          console.log("newly created campground");
                          console.log(campground);
                      }
                      });
  
   var campgrounds = [
          {name: "Jenny Lake", image:"https://farm2.staticflickr.com/1424/1430198323_c26451b047.jpg"},
          {name: "RichardBH", image:"https://photosforclass.com/download/flickr-7626464792"},
          {name: "CampAliBaba", image:"https://photosforclass.com/download/flickr-7121865553"},
          {name: "CampAliBabaHai", image:"https://photosforclass.com/download/flickr-2770447094"},
          {name: "CampAliBabaHaiYe", image:"https://photosforclass.com/download/flickr-2602356334"},
  
          ];
  
  app.get("/", function(req, res){
      res.render("landing");
  });
  
  app.get("/campgrounds", function(req, res){
  
          Campground.find({}, function(err, allCampgrouns){
              if(err){
                  console.log(err)
              }
              else {
                   res.render("campgrounds", {campgrounds:allCampgrounds});
              }
  
  
  });
  
  app.post("/campgrounds", function(req, res){
  
      var name = req.body.name
      var image = req.body.image
      var newcampground = {name: name, image: image}
      campgrounds.push(newcampground);
      res.redirect("/campgrounds");
  });
  
  app.get("/campgrounds/new" , function(req, res){
      res.render("new.ejs");
  });
  
  app.listen(process.env.PORT, process.env.IP, function(){
      console.log("YelpCamp server started!");
  });
  </code></pre>
  
  <p>Expected-
  The file should save error-free in order to start the server and run the application</p>
  
  <p>Actual-
  Getting above mentioned error</p>