We need to:

* pass in `allowArray` option;
* check if the value is an array and add error message if allowArray is false.