Download & Extend

Check $node->node_comment when nodecomment installed

Project:Fasttoggle
Version:6.x-1.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:active
Issue tags:DruBB

Issue Summary

Currently NC uses its own $node->node_comment to hold the read/write | readonly | disabled settings. This confuses fasttoggle and possibly other modules that need to know if comments are available. If possible, this should reuse the $node->comment variable for consistancy.

Michelle

Comments

#1

Title:Reuse $node->comment» Check $node->node_comment when nodecomment installed
Project:Node Comments» Fasttoggle
Version:6.x-2.x-dev» 6.x-1.x-dev
Component:Comment module inconsistencies» Code
Category:task» feature request

After talking to merlinofchaos it seems there's no easy way for nodecomment to reuse the variable because it needs to keep comment from doing its thing. But having two variables means fasttoggle won't work because it's not looking for the new variable. Moving this over to that queue to ask for this to be added. I don't have a patch right now but can probably provide one at some point if no one beats me to it. In the mean time, this is what I did in Advanced Forum:

<?php
 
// Give nodecomment (if installed) first shot at the comment setting
 
$comment_setting = (empty($node->node_comment)) ? $node->comment : $node->node_comment;
 
  if (
$comment_setting == COMMENT_NODE_READ_WRITE) {
?>

It's working fine with nodecomment installed but I haven't tested without it, yet.

Michelle

#2

@Michelle, please roll a patch if you have fasttoggle working with nodecomment.

#3

I never got them working properly together. It's something I could still use but not anything I have time for now. This issue is 1.5 years old and I don't remember much about it anymore.

Michelle