@@ -43,7 +43,6 @@ |
||
| 43 | 43 | use OCP\IUserBackend; |
| 44 | 44 | use OCP\IUserSession; |
| 45 | 45 | use OCP\User\IChangePasswordBackend; |
| 46 | -use OCP\UserInterface; |
|
| 47 | 46 | use Symfony\Component\EventDispatcher\EventDispatcher; |
| 48 | 47 | use Symfony\Component\EventDispatcher\GenericEvent; |
| 49 | 48 | |
@@ -82,7 +82,7 @@ discard block |
||
| 82 | 82 | * |
| 83 | 83 | * @param Account $account |
| 84 | 84 | * @param AccountMapper $mapper |
| 85 | - * @param null $emitter |
|
| 85 | + * @param Manager $emitter |
|
| 86 | 86 | * @param IConfig|null $config |
| 87 | 87 | * @param null $urlGenerator |
| 88 | 88 | * @param EventDispatcher|null $eventDispatcher |
@@ -473,6 +473,10 @@ discard block |
||
| 473 | 473 | return $url; |
| 474 | 474 | } |
| 475 | 475 | |
| 476 | + /** |
|
| 477 | + * @param string $feature |
|
| 478 | + * @param string $value |
|
| 479 | + */ |
|
| 476 | 480 | public function triggerChange($feature, $value = null) { |
| 477 | 481 | if ($this->emitter && \in_array($feature, $this->account->getUpdatedFields())) { |
| 478 | 482 | $this->emitter->emit('\OC\User', 'changeUser', [$this, $feature, $value]); |
@@ -30,7 +30,6 @@ |
||
| 30 | 30 | use OCP\Authentication\IAuthModule; |
| 31 | 31 | use OCP\IRequest; |
| 32 | 32 | use OCP\ISession; |
| 33 | -use OCP\IUser; |
|
| 34 | 33 | use OCP\IUserManager; |
| 35 | 34 | use OCP\Session\Exceptions\SessionNotAvailableException; |
| 36 | 35 | |
@@ -113,6 +113,8 @@ |
||
| 113 | 113 | * INTERNAL USE ONLY!! This method isn't part of the IManager interface |
| 114 | 114 | * @internal This should only be used by the RegisterNotifierEventImpl (the real implementation). |
| 115 | 115 | * Do NOT use this method outside as it might not work as expected. |
| 116 | + * @param string $id |
|
| 117 | + * @param string $name |
|
| 116 | 118 | */ |
| 117 | 119 | public function registerBuiltNotifier(INotifier $notifier, $id, $name) { |
| 118 | 120 | if (!isset($this->builtNotifiersHolder[$id]) && !isset($this->notifiersInfo[$id])) { |
@@ -134,7 +134,6 @@ |
||
| 134 | 134 | * @NoAdminRequired |
| 135 | 135 | * @NoSubadminRequired |
| 136 | 136 | * |
| 137 | - * @param string $domain Domain to remove |
|
| 138 | 137 | * @return RedirectResponse Redirection to the settings page. |
| 139 | 138 | */ |
| 140 | 139 | public function removeDomain($id) { |
@@ -109,8 +109,8 @@ |
||
| 109 | 109 | } |
| 110 | 110 | |
| 111 | 111 | /** |
| 112 | - * @param $controller |
|
| 113 | - * @param $methodName |
|
| 112 | + * @param Controller $controller |
|
| 113 | + * @param string $methodName |
|
| 114 | 114 | * @throws TwoFactorAuthRequiredException |
| 115 | 115 | * @throws UserAlreadyLoggedInException |
| 116 | 116 | */ |
@@ -274,7 +274,7 @@ discard block |
||
| 274 | 274 | * @param string $userId |
| 275 | 275 | * @param string $domain |
| 276 | 276 | * @param \OCP\IConfig $config |
| 277 | - * @param array $headers |
|
| 277 | + * @param string[] $headers |
|
| 278 | 278 | * |
| 279 | 279 | * Format of $headers: |
| 280 | 280 | * Array [ |
@@ -318,7 +318,7 @@ discard block |
||
| 318 | 318 | * This function adds the CORS headers for all domains |
| 319 | 319 | * |
| 320 | 320 | * @param Sabre\HTTP\ResponseInterface $response |
| 321 | - * @param Array $headers |
|
| 321 | + * @param string[] $headers |
|
| 322 | 322 | * |
| 323 | 323 | * Format of $headers: |
| 324 | 324 | * Array [ |
@@ -173,7 +173,7 @@ discard block |
||
| 173 | 173 | |
| 174 | 174 | /** |
| 175 | 175 | * @param Node $node |
| 176 | - * @param $correctChecksum |
|
| 176 | + * @param string $correctChecksum |
|
| 177 | 177 | * @throws NotFoundException |
| 178 | 178 | * @throws \OCP\Files\InvalidPathException |
| 179 | 179 | * @throws \OCP\Files\StorageNotAvailableException |
@@ -188,7 +188,7 @@ discard block |
||
| 188 | 188 | } |
| 189 | 189 | |
| 190 | 190 | /** |
| 191 | - * @param $path |
|
| 191 | + * @param string $path |
|
| 192 | 192 | * @param IStorage $storage |
| 193 | 193 | * @return string |
| 194 | 194 | * @throws \OCP\Files\StorageNotAvailableException |
@@ -172,6 +172,10 @@ |
||
| 172 | 172 | 'data' => ['sharedSecret' => $sharedSecret]]; |
| 173 | 173 | } |
| 174 | 174 | |
| 175 | + /** |
|
| 176 | + * @param string $url |
|
| 177 | + * @param string $token |
|
| 178 | + */ |
|
| 175 | 179 | protected function isValidToken($url, $token) { |
| 176 | 180 | $storedToken = $this->dbHandler->getToken($url); |
| 177 | 181 | return \hash_equals($storedToken, $token); |
@@ -284,6 +284,9 @@ discard block |
||
| 284 | 284 | return $this->leave(__FUNCTION__, $result); |
| 285 | 285 | } |
| 286 | 286 | |
| 287 | + /** |
|
| 288 | + * @param string $path |
|
| 289 | + */ |
|
| 287 | 290 | private function removeFromCache($path) { |
| 288 | 291 | $path = \trim($path, '/'); |
| 289 | 292 | // TODO The CappedCache does not really clear by prefix. It just clears all. |
@@ -673,7 +676,7 @@ discard block |
||
| 673 | 676 | * if smb.logging.enable is set to true in the config will log a leave line |
| 674 | 677 | * with the given function, the return value or the exception |
| 675 | 678 | * |
| 676 | - * @param $function |
|
| 679 | + * @param string $function |
|
| 677 | 680 | * @param mixed $result an exception will be logged and then returned |
| 678 | 681 | * @return mixed |
| 679 | 682 | */ |
@@ -700,6 +703,9 @@ discard block |
||
| 700 | 703 | return $result; |
| 701 | 704 | } |
| 702 | 705 | |
| 706 | + /** |
|
| 707 | + * @param string $function |
|
| 708 | + */ |
|
| 703 | 709 | private function swallow($function, \Exception $exception) { |
| 704 | 710 | if (\OC::$server->getConfig()->getSystemValue('smb.logging.enable', false) === true) { |
| 705 | 711 | Util::writeLog('smb', "$function swallowing ".\get_class($exception) |