Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

toArray's type name not effective after select #1062

Open
oli414 opened this issue Jul 9, 2018 · 0 comments
Open

toArray's type name not effective after select #1062

oli414 opened this issue Jul 9, 2018 · 0 comments

Comments

@oli414
Copy link

oli414 commented Jul 9, 2018

$resultA = ProjectQuery::create()->select(["Title",` "Description"])->find()->toArray(null, false, 'camelName');
// json: [{"Title": "X", "Description": "Y"}, {"Title": "F", "Description": "G"}]
$resultB = ProjectQuery::create()->find()->toArray(null, false, 'camelName');
// json: [{"id": 0, "title": "X", "description": "Y"}, {"id": 1, "title": "F", "description": "G"}]

I would expect "resultA" to properly camelCase the keys like in "resultB". This however does not appear to be the case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant