When retrieving nodes with a "fields" argument, the services_resource_build_index_query function in services.module throws an error as it attempts to split the fields string into an array after already having done it.
Line 470:
$fields = explode(',', $fields); // This splits the $fields string into an array
$query->fields('t', $explode(',', $fields)); // This line errors as we attempt to split the fields array again
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | index-failure-1144890.patch | 7.55 KB | marcingy |
Comments
Comment #1
marcingy commentedSetting to head. Thanks for this, patch to fix the issue and also to improve the tests so as they actually pick this issue up.
Attached patch fixes the bug deleted here, adds tests to check fields and tidies up default values for parameters in index queries.
Comment #2
kylebrowning commentedNeeds to be ported, but depends on #1063460: Add index actions to all resources supporting get
Comment #3
kylebrowning commented