Changeset 957

Show
Ignore:
Timestamp:
03/31/08 20:44:57 (8 months ago)
Author:
_ck_
Message:

[0.1.7] bug workaround for is_topic() failure to maintain signature toggle during edits

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • bbpress-signatures/trunk/bb-signatures.php

    r901 r957  
    44Plugin URI:  http://bbpress.org/plugins/topic/63 
    55Description:  allows users to add signatures to their forum posts, including an optional per-post toggle 
    6 Version: 0.16 
     6Version: 0.1.7 
    77Author: _ck_ 
    88Author URI: http://bbshowcase.org 
     
    159159function bb_signatures_checkbox() { 
    160160//  this function call must unfortunately be manually placed into edit-form.php and post-form.php templates 
    161 global $bb_post,$bb_signatures,$bb_signatures_on_page
     161global $bb_signatures,$bb_signatures_on_page,$posts,$bb_post
    162162if ($bb_signatures['allow_per_post_signature_toggle']) : 
    163163if (bb_current_user_can($bb_signatures['minimum_user_level']) ) : 
    164 if (is_topic() || !$user_id=$bb_post->poster_id) {$user_id=bb_get_current_user_info( 'id' );} 
    165 if (is_topic() || !$post_id=$bb_post->post_id) {$post_id=0;} 
     164if (isset($posts) || !isset($bb_post->poster_id)) {$user_id=bb_get_current_user_info( 'id' );} else {$user_id=$bb_post->poster_id;}    // || is_topic() 
     165if (isset($posts) || !isset($bb_post->post_id)) {$post_id=0;} else {$post_id=$bb_post->post_id;}               // || is_topic() 
    166166// if (fetch_user_signature($user_id)) {$checked="checked";} 
    167167if ($post_id && bb_signatures_exclude_posts_check($post_id)) {$checked=""; $disabled="1";} else {$checked="checked"; $disabled="0";} 
  • bbpress-signatures/trunk/readme.txt

    r901 r957  
    4141*       signatures removed from rss feeds 
    4242*       bug fix to maintain setting when posts are saved after edit  
     43 
     44= Version 0.1.7 (2008-03-31) = 
     45 
     46*       bug workaround for is_topic() failure to maintain signature toggle during edits