Modified validator check to allow type checks to be scalar values and not only arrays