Skip to:
Content

bbPress.org

Changeset 5828


Ignore:
Timestamp:
07/14/2015 12:38:19 AM (10 years ago)
Author:
johnjamesjacoby
Message:

Akismet: Clean up potential accidental inline assignment in BBP_Akismet::check_post().

This commit moves a variable assignment out of a comparison to improve code clarity.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/includes/extend/akismet.php

    r5824 r5828  
    151151
    152152            // Use post parent to get datetime of last reply on this topic
    153             if ( $reply_id = bbp_get_topic_last_reply_id( $post_data['post_parent'] ) ) {
     153            $reply_id = bbp_get_topic_last_reply_id( $post_data['post_parent'] );
     154            if ( ! empty( $reply_id ) ) {
    154155                $user_data['last_active'] = get_post_field( 'post_date', $reply_id );
    155156            }
Note: See TracChangeset for help on using the changeset viewer.