Skip to content

Commit 62e77d1

Browse files
committed
Apply memberID flag to all users
1 parent 5776ab1 commit 62e77d1

File tree

2 files changed

+7
-14
lines changed
  • src
    • components/ChallengesComponent/ChallengeList
    • containers/Challenges

2 files changed

+7
-14
lines changed

src/components/ChallengesComponent/ChallengeList/index.js

+6-13
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ class ChallengeList extends Component {
116116
searchText,
117117
selfService,
118118
this.getHandle(),
119-
this.getUserId(),
119+
this.getLoginUserId(),
120120
challengeType,
121121
challengeDate
122122
)
@@ -153,7 +153,7 @@ class ChallengeList extends Component {
153153
searchText,
154154
selfService,
155155
this.getHandle(),
156-
this.getUserId(),
156+
this.getLoginUserId(),
157157
filterChallengeType,
158158
filterDate,
159159
sortBy,
@@ -191,7 +191,7 @@ class ChallengeList extends Component {
191191
searchText,
192192
selfService,
193193
this.getHandle(),
194-
this.getUserId(),
194+
this.getLoginUserId(),
195195
filterChallengeType,
196196
filterDate,
197197
sortBy,
@@ -220,7 +220,7 @@ class ChallengeList extends Component {
220220
searchText,
221221
selfService,
222222
this.getHandle(),
223-
this.getUserId()
223+
this.getLoginUserId()
224224
)
225225
}
226226

@@ -258,13 +258,6 @@ class ChallengeList extends Component {
258258
return this.getLoginHandle()
259259
}
260260

261-
getUserId () {
262-
if (checkAdmin(this.props.auth.token)) {
263-
return null
264-
}
265-
return this.getLoginUserId()
266-
}
267-
268261
getLoginHandle () {
269262
return this.props.auth && this.props.auth.user
270263
? this.props.auth.user.handle
@@ -311,7 +304,7 @@ class ChallengeList extends Component {
311304
searchText,
312305
selfService,
313306
this.getHandle(),
314-
this.getUserId(),
307+
this.getLoginUserId(),
315308
challengeType,
316309
challengeDate,
317310
name,
@@ -357,7 +350,7 @@ class ChallengeList extends Component {
357350
'',
358351
selfService,
359352
this.getHandle(),
360-
this.getUserId(),
353+
this.getLoginUserId(),
361354
null,
362355
{},
363356
null,

src/containers/Challenges/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ class Challenges extends Component {
8585
'',
8686
selfService,
8787
isAdmin ? null : this.props.auth.user.handle,
88-
isAdmin ? null : this.props.auth.user.userId
88+
this.props.auth.user.userId
8989
)
9090
const projectLoading =
9191
window.localStorage.getItem('projectLoading') !== null

0 commit comments

Comments
 (0)