Modify all() to work with nested input arrays
Merge branch '4.0'