-
-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Cast string type for trim() #38910
Cast string type for trim() #38910
Conversation
9b31680
to
28b0dd5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think trim($fromDefault ?? "", "()");
would you consider this syntax instead?
thank you!
- Fix various psalm issues - Add as much typing as possible while preserving stable API Signed-off-by: Carl Schwan <[email protected]> Signed-off-by: dartcafe <[email protected]>
Signed-off-by: Carl Schwan <[email protected]> Signed-off-by: dartcafe <[email protected]>
Signed-off-by: Côme Chilliet <[email protected]> Signed-off-by: dartcafe <[email protected]>
Signed-off-by: dartcafe <[email protected]>
Signed-off-by: dartcafe <[email protected]>
213d396
to
2211721
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 Note
$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 Note
* | ||
* @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 Note
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
Might be a good idea to fixup the last commit into the last but one commit.
The last commits come from the master branch. I can open a clean PR if necessary. |
Summary