Hi Guys,
Did a "clean install" by installing new directory and a blank database. Started creating my own "Space" by adding sections and this warning came across:
Warning: Illegal string offset 'field_name' in oa_wiki_field_access() (line 157 of /profiles/openatrium/modules/apps/oa_wiki/oa_wiki.module).
Warning: Illegal string offset 'field_name' in og_ui_field_access() (line 823 of /profiles/openatrium/modules/contrib/og/og_ui/og_ui.module)
I did try clearing cache - the warnings were still there.
Not a blocker for sure.
Adam
Comments
Comment #1
jkingsnorth commentedConfirmed.
Comment #2
jkingsnorth commentedThis is because the field 'og_group_ref' is coming back as a string rather than an array in $field.
I don't think the right fix is to just check !empty(), surely this $field should be returning an array and not just a string? That's why the OG UI module is also throwing a warning.
You can see this by adding dsm($field); or similar into the oa_wiki_field_access hook, ~ln 157 of oa_wiki.module
Comment #3
mpotter commentedOK, tracked this down.
Looks like in the autocomplete ajax callbacks added for the new Select2Widget fields, it's doing:
which is causing field_access to be called with the name of a field instead of a full field array. We will need to write our own access function to handle this. Will work on this and get a fix for 2.30-rc2. Thanks for the report!
Comment #4
hefox commentedShould first be fixed in select2widget, then we can use that function
(I copy and pasted the menu defination from there)
Comment #5
hefox commentedComment #6
adam fermier commentedYahoo - thanks guys!
Comment #7
katrien_w commentedI applied the patch but am still seeing this error.
Should I update the media module within OA or wait for the new rc2?
Comment #8
hefox commentedWait for rc2, it needed to be fixed in both select2widget and oa_core