Download & Extend

Problem in certain scenarios when using cck_field_perms

Project:Unique field
Version:5.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

I have an error when using cck_field_perms in the situation where a certain user does not have access to edit a certain field and the field is also used for unique_field.

The error is:
Invalid argument supplied for foreach() in /home/agile/public_html/sites/all/modules/unique_field/unique_field.module on line 177.

I hope to get some feedback on my fix before I create a patch but in function "unique_field_match_value" i added this as the first line:
if (!isset($values)) {return array();}

From my quick digging around it looked like if $values is not set then the user does not have access to that field. Any feedback is appreciated.

Thanks!

Comments

#1

Status:active» fixed

Hi skassam,

Thanks for reporting this issue. Compatibility with cck_field_perms (for Drupal 5 and content_permissions for Drupal 6) should be fixed in version 1.0 of this module.

#2

Status:fixed» closed (fixed)

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

nobody click here