The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

No mails by private posts (5 posts)

  1. edik
    Posted 2 years ago #

    Am I right if I say that the plugin should send mails if a user publishes a post privately? I ask because it doesn't. The following lines in the function post_email stop private publishing notifications:

    if ( 'publish' != $new || 'publish' == $old )


  2. Samuel Wood (Otto)
    WordPress.org Tech Dude
    Plugin Author

    Posted 2 years ago #

    It doesn't send emails for private posts because, well, private. Whether it should send them or not is debatable, but yes, this is intentional.

  3. edik
    Posted 2 years ago #

    Okay, if so, I found a bug. :D
    Notifly send emails for comments on private posts. But they are also private.

    Besides a suggestion: what about a filter to allow notifications for private content? I'm sure that there are more users who need such a feature and it would prevent me from forking your plugin. And forks are evil. :D

    Currently I replaced the code above by:

    $public_statuses = array( 'publish', 'private' );
    $only_updated = in_array( $old, $public_statuses );
    $public = in_array( $new, $public_statuses );
    if ( $only_updated || ! $own_public ) return;
  4. Alberto Hornero
    Posted 2 years ago #

    @edik thanks ;-)

  5. edik
    Posted 1 year ago #

    I wrote an alternative version of the plugin with some differences.

    Now there also exists a mini plugin for my alternative which adds notifications for private posts .

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Notifly
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic