jdavidbakr / mail-tracker

Package for Laravel to inject tracking code into outgoing emails.
MIT License
562 stars 129 forks source link

Getting authentication error while using microsoft modern auth #224

Closed vivekp56 closed 1 year ago

vivekp56 commented 1 year ago

Hi, We have jdavidbakr/mail-tracker version 2.2 installed in laravel system, now we are shifting to Modern Auth to send emails and we are using laravel queue to send emails.

And we are using this event from "jdavidbakr" this package, "jdavidbakr\MailTracker\Events\EmailSentEvent" Public attribute sent_email contains the SentEmail model

If I removed this package from the composer then mail is sent through Microsoft Modern Auth but with this package, I am facing the issue related to "Swift_TransportException: Failed to authenticate on SMTP server with username "XXXXXXX" using 2 possible authenticators", is there anything you guys can help with? Do we need to upgrade the package? We are on laravel 6.20.44.

jdavidbakr commented 1 year ago

Are you still using the Swift Mailer with Modern Auth? The plugin at this version hooks into the Laravel Swift Mailer, if your Modern Auth integration replaces that then mail-tracker will not work.

vivekp56 commented 1 year ago

@jdavidbakr

Thank you for the updates, We didn't change email-related functionality. Swift Mailer is still in use, and the email tracking functionality works fine. We found the issue and resolved it on our side. Due to the package priority sequence our modern auth credentials overwrites by the mail tracker. Now, we are good at this.