Skip to content
This repository was archived by the owner on Jun 27, 2019. It is now read-only.

Commit f10528c

Browse files
fixed minor issues
1 parent 5fe9292 commit f10528c

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

server/services/comments/comments.hooks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ module.exports = {
107107
],
108108
find: [
109109
populate({ schema: userSchema }),
110-
discard('content', 'user.coverImg', 'badgeIds')
110+
discard('content', 'badgeIds')
111111
],
112112
get: [
113113
populate({ schema: userSchema })

server/services/contributions/contributions.hooks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ const candosSchema = {
5151
parentField: '_id',
5252
childField: 'contributionId',
5353
query: {
54-
$select: ['userId']
54+
$select: ['_id', 'userId']
5555
},
5656
asArray: true
5757
}

server/services/users/users.hooks.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ const cleanupPersonalData = when(isProvider('external'),
2525
);
2626

2727
const restrict = [
28-
authenticate('jwt'),
2928
restrictToOwner({
3029
idField: '_id',
3130
ownerField: '_id'
@@ -97,6 +96,7 @@ const thumbnailOptions = {
9796
module.exports = {
9897
before: {
9998
all: [
99+
authenticate('jwt'),
100100
search(),
101101
search({ // regex search on given fields
102102
fields: ['name', 'email']
@@ -137,7 +137,6 @@ module.exports = {
137137
],
138138
patch: [
139139
...restrict,
140-
// hashPassword(),
141140
disableMultiItemChange(),
142141
lowerCase('email', 'username'),
143142
// Only set slug once

0 commit comments

Comments
 (0)