forked from hippoz/brainlet
what have i done
This commit is contained in:
parent
c87c7f98d3
commit
c293389359
3 changed files with 8 additions and 3 deletions
5
.gitignore
vendored
Executable file
5
.gitignore
vendored
Executable file
|
@ -0,0 +1,5 @@
|
||||||
|
node_modules
|
||||||
|
node_modules/
|
||||||
|
node_modules/*
|
||||||
|
|
||||||
|
secret.js
|
|
@ -100,7 +100,7 @@ app.get('/category/:category/info', [
|
||||||
}
|
}
|
||||||
|
|
||||||
const categoryId = req.params.category;
|
const categoryId = req.params.category;
|
||||||
const category = await Category.findById(categoryId).populate('posts.creator');
|
const category = await Category.findById(categoryId).populate('posts.creator', 'username _id');
|
||||||
|
|
||||||
if (!category) {
|
if (!category) {
|
||||||
res.status(404).json({
|
res.status(404).json({
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
ports: {
|
ports: {
|
||||||
mainServerPort: 25,
|
mainServerPort: 3000,
|
||||||
},
|
},
|
||||||
address: '188.25.251.46',
|
address: 'localhost',
|
||||||
mongoUrl: 'mongodb://localhost:27017/app',
|
mongoUrl: 'mongodb://localhost:27017/app',
|
||||||
bcryptRounds: 10,
|
bcryptRounds: 10,
|
||||||
roleMap: {
|
roleMap: {
|
||||||
|
|
Loading…
Reference in a new issue