IMO the following call returns illogical results:
$countries = countries_get_countries('all', $filters['countries'] = array('de', 'be') )
I expect 2 country-objects, but get all of them.
See below 'patch'.
function countries_get_countries($property = 'all', $filters = array()) {
$countries = entity_load_multiple_by_name('country');
- if ($property == 'all') {
- return $countries;
- }
$filtered_countries = countries_filter($countries, $filters);
if ($property == 'all' || empty($property)) {
return $filtered_countries;
}
...
}
Comments
Comment #1
alan d. commentedJust to be on the safe side, I'll see what the tests say.
Comment #2
alan d. commentedtriggering test bot again
Comment #3
alan d. commentedExcellent, the tests are fully functional again. These tests needed adjusting due to:
1) New string changes to bring the countries list fully inline with the ISO standard.
2) An error in the import where no imports were selected (committed a few days ago).
3) An error in the import where the enabled flag was ignored when this was set to 0.
Right, back to the issue at hand, this has been pushed into dev.