Hi,

Just separating this from here.

In short, all node types are allowed in the forums, but only forum topics are covered by the forum_access module.

(to add a nodetype, go to admin/taxonomy, then click edit on the relevant forum vocab, and check any nodetypes you want to allow.)

I AM using this module on a live site (yes, I can be a little crazy... and deserve what I get for being so cavalier.), so is there a way to hide/disable all poll nodes (even for all users - will turning off the poll module do this?) while this is sorted out?

Comments

salvis’s picture

You should be able to mass unpublish the poll nodes at admin/content/node.

Thank you for reporting this issue!

naheemsays’s picture

Looking at the code, the nodetype is only used in two places:

1. Line 33 - forum_access_node_access_records: if ($node->type == 'forum') {

No idea if this if statement can just be removed or needs to be replaced.

2. line 280 - forum_access_nodeapi: if ($node && $node->type == 'forum' && $op == 'insert') {

Just removing the $node->type check should allow check from the nodes to be given their proper permissions. (unless that will mess with oter modules?)

Neither of these seem to be setting the access permissions for already existing nodes? or is that done through the latter nodeapi function?

no idea on the impact to performance removing these checks will cause - all nodes will go through the checks instead of just forum nodes. (not a problem for me since about 99% of my site is a forum.)

salvis’s picture

The access permissions are set at node creation/update time and stored in the {node_access} table.

I needed to get an authoritative answer on #231691: Is the {forum} table redundant? first. As you can see, things are a bit more complex under D6 than they used to be under D5, and that's exactly why we're having the beta test. I'm looking into a fix.

salvis’s picture

Status: Active » Fixed

Committed to HEAD.

naheemsays’s picture

thanks it works. (after this update, do I need to rebuild permissions for everything again? or will it all just work?)

(just a note - unpublishing the couplw of polls that were recent did throw up errors (something to do with line 38 or something) and then in the forums, it said they had been moved. I had to use tracker to get to the nodes, click edit, then save and they were once again working. This is probably NOT a bug in Forum_access, but I thought I would mention it.)

salvis’s picture

Thank you for the feedback.

To be really sure what is happening, please install and enable devel_node_access temporarily, as explained on the "create issue" page. Especially if you have nodes that were moved between forums or if you have moderators defined, then you should take a close look at those nodes.

I don't have poll, but I tried a page and didn't see any error messages. Would you make a quick test to verify that the errors are gone?

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

naheemsays’s picture

Version: 6.x-1.x-dev » 6.x-1.0-beta1
Status: Closed (fixed) » Active

Just upgraded tot he beta and this issue has somehow arisen again. Got a poll that should not been by anyone whois not a member of a particular group - but there is atleast one poll that anonymous users can see - I have rebuilt permissions, but no cure.

EDIT - and it does not seem to be happening to all nodes - so far just one particular poll, whereas a couple of others I have tested are unaffected. Confused.

naheemsays’s picture

This may be safe to ignore, but I will leave it toy you to decide.

After the above post, I went into the private forum again and it said that the particular node had been moved to another forum (which was open), but I had not done that, and when clicking edit on the forum, it still said it was in the correct forum. Saving it fixed the problem.

Not sure if the problem is here or elsewhere.

salvis’s picture

Status: Active » Closed (fixed)

You didn't save the Devel Node Access records, did you?

Upgrading FA cannot do something like "the particular node had been moved to another forum (which was open)", and I'm reasonably sure that this is unrelated to FA. FA cannot change taxonomy terms of nodes.

I continue to be very interested in hearing about any irregularities that could be related to FA. Thanks for reporting.

naheemsays’s picture

no - this was on a live site where Devel was not installed.

I will keep an eye out and see if I spot any more instances...

As for the node, the private forum was saying that it had been moved... but it had not. From the UI, it had the correct taxonomy association. Re saving the node without making any changes fixed the issue.

I am willing to write this one occasion off as something else for now, but sine you wanted reports, I guess this is something to be mindful of about.

salvis’s picture

Without the DNA information, the chances of getting any idea of what is happening is just about zero. (BTW, you can install DNA without the rest of Devel — this costs some processing time for the users that have it enabled, but it's absolutely risk-free, because it has no active features.)

IAC, the information that a node has been moved certainly did not come from FA. FA has no such concept. Whatever it was that displayed that information and that reversed it upon re-saving, that is the primary suspect. Without knowing what that was, and what kind of (mis-?)configuration it created, we have no way to find out whether FA behaved correctly or not.