Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Support vupdraft

    (@vupdraft)

    I am just checkin with our development team where we are on this.

    Plugin Contributor Venkat Raj

    (@webulous)

    @ashleighm How do you conclude that it is WP Optimize that causes the issue? Yes, WP Optimize uses wp_mail but it is not declaring it.

    See the screenshot: https://prnt.sc/3SEqUoq6cDQv

    In my case, it is Mailgun plugin that declares wp_mail Disabling it solves the issue.

    Thread Starter ashleighm

    (@ashleighm)

    @webulous Because in testing when I deactivate the wp optimize plugin I no longer get the “FATAL Postman: Postman: wp_mail has been declared by another plugin or theme, so you won’t be able to use Postman until the conflict is resolved.” in my error log on every page load and bot crawl.

    https://ibb.co/QPTZxSH

    I don’t have the mailgun plugin. I’ve never heard of it.

    Plugin Contributor Venkat Raj

    (@webulous)

    @ashleighm It doesn’t have to be MailGun Any other plugin that deals with sending email such as mailin by sendinblue or CF7
    See here https://ww.wp.xz.cn/support/topic/wp_mail-declared-by-another-plugin-theme/

    If you have enabled Log events to email in Logging settings in WPO, try removing it.

    Thread Starter ashleighm

    (@ashleighm)

    I don’t use any other plugin that alters the way the core sends mail.

    In testing, the error message goes away when I deactivate WP Optimize. The error message persists when switched to 2022 theme and only Post SMTP and WP Optimize are active, and all other plugins are deactivated.

    The error does not include more information or a url to where wp_mail is being declared like in your screenshot.

    I have gone through similar threads in the Post SMTP forum and don’t have any code in my config file. I do have an open support thread with them as well.

    Plugin Contributor Venkat Raj

    (@webulous)

    @ashleighm Could you please comment out this line and see if that fixes issue? https://plugins.trac.ww.wp.xz.cn/browser/post-smtp/trunk/Postman/extra/no-localhost-mails.php#L8

    If there are no other plugins, except WPO and Post SMTP, then probably post smtp wrongly conclude cached site as localhost and define wp_mail

    Mere existence of wp_mail sets $this->bindError as true

    As I said earlier, WP Optimize don’t declare function wp_mail which you can test by searching the source code. You are saying that no other plugins are there and theme as well doesn’t declare it. So above is the only possibility I see

    Thread Starter ashleighm

    (@ashleighm)

    Removing that line didn’t have an effect.

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Conflict with Post SMTP causing wp_mail declared error’ is closed to new replies.