***res.redirect function is used to redirect the user to another page by clicking a button. But the function's not working. Please find the code below.***

```
    const express = require("express");
const bodyParser = require("body-parser");
const request = require("request");
const https = require("https");

const app = express();

app.use(express.static("public"));
app.use(bodyParser.urlencoded({
    extended: true
}));

app.get("/", function (req, res) {
    res.sendFile(__dirname + "/signup.html");
});

app.post("/failure", function (req, res) {
    res.redirect("/");
});

app.post("/success", function(req, res) {
    res.redirect("/");
});

app.listen(process.env.PORT || 3000, function () {
    console.log("The server is running at port 3000");
});

```