mirror of
https://github.com/ClaytonWWilson/CS307-Team24.git
synced 2026-04-26 01:45:04 +00:00
Fixed conflicts with Sprint 2 checkpoint and the most up-to-date version
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
/* eslint-disable prefer-arrow-callback */
|
||||
/* eslint-disable promise/always-return */
|
||||
const admin = require('firebase-admin');
|
||||
|
||||
@@ -17,7 +16,6 @@ exports.putPost = (req, res) => {
|
||||
|
||||
admin.firestore().collection('posts').add(newPost)
|
||||
.then((doc) => {
|
||||
doc.update({postId: doc.id})
|
||||
const resPost = newPost;
|
||||
resPost.postId = doc.id;
|
||||
return res.status(200).json(resPost);
|
||||
@@ -65,7 +63,3 @@ exports.getallPosts = (req, res) => {
|
||||
res.status(500).send("Failed to retrieve posts from database.", err);
|
||||
});
|
||||
};
|
||||
|
||||
exports.getFilteredPosts = (req, res) => {
|
||||
admin.firestore().collection('posts').where('userHandle', '==', 'new user').where('microBlogTopics', '==')
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user