add ability to set custom validator as closure for type/subType
Merge branch 'develop'