fix max depth check in getTwigChildList #360