Added case for when values is not an array