Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
integration
prechecker
Commits
a0034bb0
Commit
a0034bb0
authored
Jan 11, 2016
by
jun
Committed by
Eloy Lafuente
Mar 08, 2016
Browse files
MDL-52433 user: Remove unnecessary capability check
parent
89b97390
Changes
1
Hide whitespace changes
Inline
Side-by-side
user/index.php
View file @
a0034bb0
...
...
@@ -652,7 +652,6 @@ if ($mode === MODE_USERDETAILS) { // Print simple listing.
$row
->
cells
[
1
]
->
text
.
=
get_string
(
'role'
)
.
get_string
(
'labelsep'
,
'langconfig'
)
.
$user
->
role
.
'<br />'
;
}
if
(
$user
->
maildisplay
==
1
or
(
$user
->
maildisplay
==
2
and
(
$course
->
id
!=
SITEID
)
and
!
isguestuser
())
or
has_capability
(
'moodle/course:viewhiddenuserfields'
,
$context
)
or
in_array
(
'email'
,
$extrafields
)
or
(
$user
->
id
==
$USER
->
id
))
{
$row
->
cells
[
1
]
->
text
.
=
get_string
(
'email'
)
.
get_string
(
'labelsep'
,
'langconfig'
)
.
html_writer
::
link
(
"mailto:
$user->email
"
,
$user
->
email
)
.
'<br />'
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment