Skip to content

Commit

Permalink
Retrying linking of files
Browse files Browse the repository at this point in the history
Co-authored-by: Orian <[email protected]>
Co-authored-by: Juliette <[email protected]>
Co-authored-by: Miah <[email protected]>
  • Loading branch information
4 people committed Jan 27, 2022
1 parent 8070c6e commit dc4dea5
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion database/model.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const db = require("./connection.js");
const db = require("../connection.js");

function createUserDB(name, email, hash) {
const INSERT_USER = `
Expand Down
2 changes: 1 addition & 1 deletion routes/home.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const model = require("../database/model.js");
const db = require("./database/connection.js");
const db = require("../database/connection.js");

function get(request, response) {
const html = `
Expand Down
2 changes: 1 addition & 1 deletion routes/login.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const auth = require("../auth.js");
const db = require("./database/connection.js");
const db = require("../database/connection.js");

function get(request, response) {
const html = `
Expand Down
2 changes: 1 addition & 1 deletion routes/signup.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const auth = require("../auth.js");
const db = require("./database/connection.js");
const db = require("../database/connection.js");

function get(request, response) {
const html = `<!DOCTYPE html>
Expand Down
6 changes: 3 additions & 3 deletions server.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const express = require("express");
//initialise db object
const db = require("./database/connection.js");
const db = require("../database/connection.js");
const server = express();
const cookieParser = require("cookie-parser");

Expand All @@ -10,8 +10,6 @@ server.use(staticHandler);
const bodyParser = express.urlencoded({ extended: false });
server.use(bodyParser);

const PORT = process.env.PORT || 3333;

const home = require("./routes/home");
const signup = require("./routes/signup");
const login = require("./routes/login");
Expand All @@ -33,6 +31,8 @@ server.post("/newsfeed", newsfeed.post);
server.post("/signup", signup.post);
server.post("/login", login.post);

const PORT = process.env.PORT || 3333;

server.listen(PORT, () => {
console.log(`listening on http://localhost:${PORT}`);
});

0 comments on commit dc4dea5

Please sign in to comment.