All posts from db can now show on home page timeline

This commit is contained in:
Aaron Sun
2019-10-30 18:04:35 -04:00
parent a61c296ddf
commit 26afabe709
6 changed files with 123 additions and 29 deletions

View File

@@ -44,11 +44,12 @@ app.get("/user", fbAuth, getAuthenticatedUser);
/*------------------------------------------------------------------*
* handlers/post.js *
*------------------------------------------------------------------*/
const { getallPostsforUser, putPost
} = require("./handlers/post");
const { getallPostsforUser, getallPosts, putPost } = require("./handlers/post");
app.get("/getallPostsforUser", fbAuth, getallPostsforUser);
app.get("/getallPosts", getallPosts);
// Adds one post to the database
app.post("/putPost", fbAuth, putPost);