add support for arrays to the alternatives.when() method in order to validate a schema against multiple keys