Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
me
Commits
e28e5bf8
Commit
e28e5bf8
authored
Jun 24, 2015
by
nohup
Browse files
Issue
#135533
by akosipax: Added check for current user
parent
53ccea3c
Changes
1
Hide whitespace changes
Inline
Side-by-side
includes/me_plugin_argument_validate_me_alias.inc
View file @
e28e5bf8
...
...
@@ -88,6 +88,14 @@ class me_plugin_argument_validate_me_alias extends views_plugin_argument_validat
// and check to be sure.
foreach
(
$uid_args
as
$key
=>
$uid_arg
)
{
$uid_args
[
$key
]
=
_me_check_arg
(
$uid_arg
,
$this
->
argument
->
options
[
'me_validate_user_argument_type'
]
==
'name'
,
FALSE
);
//Make sure we only allow access to the current user
if
(
is_numeric
(
$uid_args
[
$key
]))
{
if
(
$uid_args
[
$key
]
!=
$GLOBALS
[
'user'
]
->
uid
)
{
return
FALSE
;
}
}
else
if
(
$uid_args
[
$key
]
!=
$GLOBALS
[
'user'
]
->
name
)
{
return
FALSE
;
}
}
$argument
=
implode
(
$seperator
,
$uid_args
);
...
...
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