UnionOfRAD/lithium — pull request #688 by jails (2012-11-20 16:11:47+00:00)
Title: Optimise Model::key() and fix some issues

Refactoring of #582:
- function added to reduce the per-method cyclomatic complexity limit (It also reduce one nest level).

Fix :
- with multiples keys return `null` if one of them miss in the datas
- Model::key(array()) return `null` instead of returning the id.

Optimisation :
- `::to('array')` is no more the default behavior for looking for key in entities
- removing the use of method_exists()