Hallo,

We had some troubles with this module because of the double appearance of the option "Allow comments to alter this field" in the settings section of the CCK fields (when changing basic information of a CCK field, the option appears again). Changing both options lead to some conflicts where the new setting was not stored and nodes including comments with CCK field changes could not be displayed anymore (Fatal error: Cannot access empty property in /sites/all/modules/comment_cck/comment_cck.module on line 158).

After some investigation I found some NULL values because of wrong (missing) array indices and corrected them. Then I introduced some new conditions in the form alter hook to get rid of the second appearance of the option in the administration section.

Here are my changes in patch form and the resulting module file itself, it works fine for me and I hope it helps others, too.

Comments

klausi’s picture

StatusFileSize
new9.19 KB
new1.61 KB

Update: Changed the additional if-condition, because it was language dependent.

criz’s picture

Status: Needs work » Needs review

thx, the module is working as supposed now I think...

agentrickard’s picture

Status: Needs review » Reviewed & tested by the community

Bug confirmed. The patch removes the checkbox from the initial (basic field information) screen, which should be acceptable.

When you go from the field editing form to the 'edit basic information' form, the Comment CCK value is dropped. The patch also corrects $form_state['values'] usage instead of the old $form_values inside _comment_cck_submit().

arhak’s picture

subscribing

sanduhrs’s picture

Bug confirmed, the attached patch works well.

joshuajabbour’s picture

StatusFileSize
new1.62 KB

Here's a new patch that doesn't conflict with #309367: Not Compatible with CCK 6.x-2.1. The patch in that issue should be applied first. I'm leaving this one as RTBC as the change is just a small change to the function name in the previous patch.

joshuajabbour’s picture

I've written a new, unified patch that fixes this issue along with a few others. It's listed under #420092: Bring comment_cck up-to-date, combine patches and can (should) be applied in place of the patch above.

mitchell’s picture

Status: Closed (fixed) » Fixed

Committed. Thanks!

Status: Reviewed & tested by the community » Closed (fixed)

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

Status: Fixed » Closed (fixed)

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