Simplify method HtmlHelper::nestedList()

Docs for https://github.com/cakephp/cakephp/pull/3291