Skip to content

Conversation

@jpmg-mb
Copy link

@jpmg-mb jpmg-mb commented Sep 2, 2024

Summary

When generating a calendar event invite email from an event generated within thu
nderbird or similar application, nextcloud generates a From line that does not i
dentify the person generating the invite. This patch makes a further attempt to
extract a real name and add it to the From line. I've been running this patch in
formally against most nextcloud versions from v25.0.4 onwards, and it has fixed
the issue, and not caused any observed problems.

@GalacticWave @SebastianKrupinski

[ apologies, 2nd attempt at a PR, based on master this time ]

TODO

  • ...

Checklist

@miaulalala
Copy link
Contributor

Please sign off your commit 🙏


/* if $senderName still NULL, see if userManager has a match
* for the sender email now it's been extracted ... */
if ($senderName === null) {

Check notice

Code scanning / Psalm

DocblockTypeContradiction

string does not contain null
/* if $senderName still NULL, see if userManager has a match
* for the sender email now it's been extracted ... */
if ($senderName === null) {
$iumatches = $this->userManager->getByEmail($sender);

Check failure

Code scanning / Psalm

UndefinedThisPropertyFetch

Instance property OCA\DAV\CalDAV\Schedule\IMipPlugin::$userManager is not defined
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to be serious, I also see no userManager in this class.

@jpmg-mb
Copy link
Author

jpmg-mb commented Sep 2, 2024

(now signed-off; apologies for failing to do so originally!)

@susnux susnux added this to the Nextcloud 31 milestone Sep 2, 2024
@SebastianKrupinski
Copy link
Contributor

Hi @jpmg-mb Thank you for the pull request!!

This should no longer be an issue... This should have been addressed by the following PR #45098 And should now be working...

The following line... actually pulls the user name form the system...

} elseif ($this->userSession->getUser() !== null) {
$senderName = trim($this->userSession->getUser()->getDisplayName());

@jpmg-mb
Copy link
Author

jpmg-mb commented Sep 2, 2024

@SebastianKrupinski - thank you for looking at it!

is that other patch going to get backported to v29?

@SebastianKrupinski
Copy link
Contributor

@SebastianKrupinski - thank you for looking at it!

is that other patch going to get backported to v29?

I don't see an issue with it... Just waiting for an answer from someone to make sure they don't have any objections

@SebastianKrupinski
Copy link
Contributor

@SebastianKrupinski - thank you for looking at it!

is that other patch going to get backported to v29?

Got a go ahead for this... I'll get it in this week

@jpmg-mb
Copy link
Author

jpmg-mb commented Sep 6, 2024

I'm going to close this PR, as I've been able to verify that the existing fix mentioned above does indeed resolve the problem I wrote this to solve 8-)

@jpmg-mb jpmg-mb closed this Sep 6, 2024
@SebastianKrupinski
Copy link
Contributor

@jpmg-mb Thanks for testing and letting me know!!! I'm glad your issue is fixed.

@github-actions
Copy link
Contributor

Hello there,
Thank you so much for taking the time and effort to create a pull request to our Nextcloud project.

We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process.

Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6

Thank you for contributing to Nextcloud and we hope to hear from you soon!

(If you believe you should not receive this message, you can add yourself to the blocklist.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: From Name is not setting properly in Calendar invitations created from Thunderbird

4 participants