Merge pull request #12181 from MrPetovan/bug/warnings
Address a couple of warnings
This commit is contained in:
commit
1a54fc2140
|
@ -788,7 +788,7 @@ function photos_content(App $a)
|
||||||
// photos/name/image/xxxxx/edit
|
// photos/name/image/xxxxx/edit
|
||||||
// photos/name/image/xxxxx/drop
|
// photos/name/image/xxxxx/drop
|
||||||
|
|
||||||
$user = User::getByNickname(DI::args()->getArgv()[1]);
|
$user = User::getByNickname(DI::args()->getArgv()[1] ?? '');
|
||||||
if (!DBA::isResult($user)) {
|
if (!DBA::isResult($user)) {
|
||||||
throw new HTTPException\NotFoundException(DI::l10n()->t('User not found.'));
|
throw new HTTPException\NotFoundException(DI::l10n()->t('User not found.'));
|
||||||
}
|
}
|
||||||
|
|
|
@ -531,7 +531,7 @@ class Notify extends BaseRepository
|
||||||
// Ensure that the important fields are set at any time
|
// Ensure that the important fields are set at any time
|
||||||
$fields = ['nickname', 'account_removed', 'account_expired'];
|
$fields = ['nickname', 'account_removed', 'account_expired'];
|
||||||
$user = Model\User::getById($params['uid'], $fields);
|
$user = Model\User::getById($params['uid'], $fields);
|
||||||
if ($user['account_removed'] || $user['user_expired']) {
|
if ($user['account_removed'] || $user['account_expired']) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user