-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cleanup comments code #35424
Cleanup comments code #35424
Conversation
CarlSchwan
commented
Nov 25, 2022
- Fix various psalm issues
- Add as much typing as possible while preserving stable API
98eabd0
to
6ed35a6
Compare
public function handle(Event $event): void { | ||
if (!($event instanceof CommentsEntityEvent)) { | ||
// Unrelated | ||
return; | ||
} | ||
|
||
$event->addEntityCollection('files', function ($name) { | ||
$nodes = \OC::$server->getUserFolder()->getById((int)$name); | ||
$event->addEntityCollection('files', function ($name): bool { |
Check notice
Code scanning / Psalm
MissingClosureParamType
$event->addEntityCollection('files', function ($name) { | ||
$nodes = \OC::$server->getUserFolder()->getById((int)$name); | ||
$event->addEntityCollection('files', function ($name): bool { | ||
$nodes = $this->rootFolder->getUserFolder($this->userId)->getById((int)$name); |
Check notice
Code scanning / Psalm
PossiblyNullArgument
/rebase |
conflicts :/ |
Tests failing |
* | ||
* @param array $mentions | ||
* @return string[] containing the mentions, e.g. ['alice', 'bob'] | ||
* @return list<string> containing the mentions, e.g. ['alice', 'bob'] |
Check notice
Code scanning / Psalm
MoreSpecificReturnType
CI failure... |
/rebase |
3a7e5f1
to
7ccf065
Compare
CI failure related afaics |
/rebase |
7ccf065
to
7fa58da
Compare
- Fix various psalm issues - Add as much typing as possible while preserving stable API Signed-off-by: Carl Schwan <[email protected]>
Signed-off-by: Carl Schwan <[email protected]>
Signed-off-by: Côme Chilliet <[email protected]>
7fa58da
to
7aa97dc
Compare