-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
[stable29] fix(caldav): Do not load IMipPlugin before user auth and session is c… #47790
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
Conversation
miaulalala
left a comment
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.
Please remove the commented out code, otherwise it looks good!
| /* | ||
| $this->user->method('getUID'); | ||
| $this->user->method('getDisplayName'); | ||
| */ |
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.
| /* | |
| $this->user->method('getUID'); | |
| $this->user->method('getDisplayName'); | |
| */ |
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.
Done
| $senderName = $this->userManager->getDisplayName($this->userId); | ||
| // Due to a bug in sabre, the senderName property for an iTIP message can actually also be a VObject Property | ||
| // If the iTIP message senderName is null or empty use the user session name as the senderName | ||
| if (($iTipMessage->senderName instanceof Parameter) && !empty(trim($iTipMessage->senderName->getValue()))) { |
Check notice
Code scanning / Psalm
PossiblyNullArgument
| // Due to a bug in sabre, the senderName property for an iTIP message can actually also be a VObject Property | ||
| // If the iTIP message senderName is null or empty use the user session name as the senderName | ||
| if (($iTipMessage->senderName instanceof Parameter) && !empty(trim($iTipMessage->senderName->getValue()))) { | ||
| $senderName = trim($iTipMessage->senderName->getValue()); |
Check notice
Code scanning / Psalm
PossiblyNullArgument
| } elseif (is_string($iTipMessage->senderName) && !empty(trim($iTipMessage->senderName))) { | ||
| $senderName = trim($iTipMessage->senderName); | ||
| } elseif ($this->userSession->getUser() !== null) { | ||
| $senderName = trim($this->userSession->getUser()->getDisplayName()); |
Check notice
Code scanning / Psalm
PossiblyNullReference
|
|
||
| // calendar plugins | ||
| if ($this->requestIsForSubtree(['calendars', 'public-calendars', 'system-calendars', 'principals'])) { | ||
| $this->server->addPlugin(new DAV\Sharing\Plugin($authBackend, \OC::$server->getRequest(), \OC::$server->getConfig())); |
Check notice
Code scanning / Psalm
DeprecatedMethod
|
|
||
| // calendar plugins | ||
| if ($this->requestIsForSubtree(['calendars', 'public-calendars', 'system-calendars', 'principals'])) { | ||
| $this->server->addPlugin(new DAV\Sharing\Plugin($authBackend, \OC::$server->getRequest(), \OC::$server->getConfig())); |
Check notice
Code scanning / Psalm
DeprecatedMethod
| \OC::$server->getCommentsManager(), | ||
| $userSession | ||
| )); | ||
| if (\OC::$server->getConfig()->getAppValue('dav', 'sendInvitations', 'yes') === 'yes') { |
Check notice
Code scanning / Psalm
DeprecatedMethod
| \OC::$server->getCommentsManager(), | ||
| $userSession | ||
| )); | ||
| if (\OC::$server->getConfig()->getAppValue('dav', 'sendInvitations', 'yes') === 'yes') { |
Check notice
Code scanning / Psalm
DeprecatedMethod
…reated Signed-off-by: SebastianKrupinski <[email protected]>
c7fa4da to
d18c6af
Compare
Back port for #45081
Do not load IMipPlugin before user is authenticated and user session is initialized