[DBAL-626] [GH-386] Fix Index construction Created: 09/Oct/13  Updated: 17/Oct/13  Resolved: 17/Oct/13

Status: Resolved
Project: Doctrine DBAL
Component/s: None
Affects Version/s: None
Fix Version/s: 2.5
Security Level: All

Type: Bug Priority: Major
Reporter: Doctrine Bot Assignee: Guilherme Blanco
Resolution: Fixed Votes: 0
Labels: None


This issue is created automatically through a Github pull request on behalf of deeky666:

Url: https://github.com/doctrine/dbal/pull/386


This PR fixes an uncommon but possible use case where an `Index` is constructed with an empty columns array. Following calls to `Index::getColumns()` lead to a PHP warning `array_keys() expects parameter 1 to be array, null given` as the `$_columns` property is not properly initialized.

Comment by Doctrine Bot [ 09/Oct/13 ]

A related Github Pull-Request [GH-386] was closed:

Comment by Marco Pivetta [ 17/Oct/13 ]

Merged: https://github.com/doctrine/dbal/commit/a619261b6b96341951f93d228493818ba334d0f6

Generated at Fri Oct 09 10:16:11 EDT 2015 using JIRA 6.4.10#64025-sha1:5b8b74079161cd76a20ab66dda52747ee6701bd6.