summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2015-12-11 13:52:04 +0100
committerJoas Schilling <nickvergessen@owncloud.com>2015-12-17 16:37:48 +0100
commitf85ee56a016105bb5a721ab82a6be46591abfdab (patch)
treea5f98437d583bf927bbb36816593caa414c48425 /lib
parent04c2247b0d96df632e7660a5143777e0b1adbf08 (diff)
downloadnextcloud-server-f85ee56a016105bb5a721ab82a6be46591abfdab.tar.gz
nextcloud-server-f85ee56a016105bb5a721ab82a6be46591abfdab.zip
Check if user isset in $_REQUEST first
Diffstat (limited to 'lib')
-rw-r--r--lib/private/util.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/private/util.php b/lib/private/util.php
index e06493b09be..a802c0f0ae1 100644
--- a/lib/private/util.php
+++ b/lib/private/util.php
@@ -949,9 +949,11 @@ class OC_Util {
$parameters['canResetPassword'] = true;
if (!\OC::$server->getSystemConfig()->getValue('lost_password_link')) {
- $user = \OC::$server->getUserManager()->get($_REQUEST['user']);
- if ($user instanceof IUser) {
- $parameters['canResetPassword'] = $user->canChangePassword();
+ if (isset($_REQUEST['user'])) {
+ $user = \OC::$server->getUserManager()->get($_REQUEST['user']);
+ if ($user instanceof IUser) {
+ $parameters['canResetPassword'] = $user->canChangePassword();
+ }
}
}