Making WordPress.org


Ignore:
Timestamp:
07/12/2017 02:43:36 AM (7 years ago)
Author:
SergeyBiryukov
Message:

Support Forums: Add "Always notify me via email of follow-up posts in any topics I reply to" checkbox to user profile.

Fixes #6.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/support-forums/inc/class-hooks.php

    r5639 r5657  
    5151
    5252    /**
    53      * Check "Notify me of follow-up replies via email" checkbox for new topics by default.
     53     * Check "Notify me of follow-up replies via email" box for new topics by default.
     54     *
     55     * If the user has enabled "Always notify me via email of follow-up posts" option
     56     * in their profile, check the box for new replies as well.
    5457     *
    5558     * @param string $checked Checked value of topic subscription.
     
    5760     */
    5861    public function check_topic_subscription_checkbox( $checked ) {
    59         if ( bbp_is_single_forum() || bbp_is_single_view() ) {
     62        if (
     63            bbp_is_single_forum() || bbp_is_single_view()
     64        ||
     65            get_user_option( 'auto_topic_subscription' )
     66        ) {
    6067            $checked = checked( true, true, false );
    6168        }
Note: See TracChangeset for help on using the changeset viewer.