Add $ROOT substitution variable

This new variable allows you to retrieve the ID of the category or folder root.
use findPk instead of findOneById. The findPk method puts the object instance in a pool and the next time you call findPk with the same id, the method return the instance found in the pool instead of creating a new query.