Closed my2ter closed 5 years ago
FYI,
When you visit the field settings, it does look like Craft allows you to only select those specific sources, but when you use that field on an entry you can actually select everything.
@my2ter issue fixed in latest release.
Hi,
Should be quite simple to fix.
When you create the sources allowed for an Entry field, the migration's code does:
$field['typesettings']['sources'] = join($newSources);
This will generate in your DB:
Craft is expecting an array
Your code should be:
$field['typesettings']['sources'] = in_array('*', $newSources) ? '*' : $newSources;
Hope it does make sense :) Cheers